This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.

Bug 28826 - Add support for key uniquess checking
Summary: Add support for key uniquess checking
Status: STARTED
Alias: None
Product: utilities
Classification: Unclassified
Component: Properties (show other bugs)
Version: 3.x
Hardware: All All
: P2 blocker (vote)
Assignee: Jan Peska
URL:
Keywords:
Depends on:
Blocks: 32121
  Show dependency tree
 
Reported: 2002-11-18 10:32 UTC by _ pkuzel
Modified: 2013-05-01 19:53 UTC (History)
0 users

See Also:
Issue Type: ENHANCEMENT
Exception Reporter:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description _ pkuzel 2002-11-18 10:32:37 UTC
I found several bundles containing multiple values for the  
same key. It should be checked at UI interface as well as  
at API interface. 
 
At API level a contains() method and checked exception can 
be enough: 
 
public class KeyException extends Exception { 
   String getKey(); 
   /** Get exiting value. */ 
   String getOldValue(); 
   /** Get conflicting value. */ 
   String getNewValue(); 
} 
 
Another approach (supposing that adding duplicite key is a 
programming error) is to extend runtime 
IllegalStateException instead of Exception. 
 
In text editor interface a key can be annotated once user 
type '=' producing duplicite key.
Comment 1 Marian Petras 2005-05-13 15:45:20 UTC
Accepted.
Comment 2 markiewb 2013-05-01 19:53:06 UTC
Obsolete target milestone. Change from 6.x to TBD