[Bug 908168] New: Review Request: openprops - A fork of java.util.Properties from OpenJDK
by Red Hat Bugzilla
Product: Fedora
https://bugzilla.redhat.com/show_bug.cgi?id=908168
Bug ID: 908168
Summary: Review Request: openprops - A fork of
java.util.Properties from OpenJDK
Product: Fedora
Version: rawhide
Component: Package Review
Severity: medium
Priority: medium
Reporter: pahuang(a)redhat.com
Spec URL: https://www.dropbox.com/s/o4yjlbky6k9i7np/openprops.spec
SRPM URL:
https://www.dropbox.com/s/5wjfyfpy5s158t7/openprops-0.6-1.fc17.src.rpm
Description:
OpenProps is a tiny Java library which reads and writes .properties files using
the same code as java.util.Properties from the OpenJDK, but enhanced so that it
preserves the order of entries within the file, and it also preserves
comments in the file. This means that a Properties editor or a file converter
written to use OpenProps won't have to lose comments or mess up the order of
entries.
By using OpenJDK code, OpenProps should handle all the old corner-cases in
exactly the same way Java does. The handling of whitespace and comments is
tested by a number of JUnit tests. But please let me know if you find a bug!
Note the following differences from java.util.Properties:
1. preserves comments and the order of entries in the file
2. storeToXml doesn't use the Sun DTD (or any DTD) because it adds attributes
for comments.
3. equals() and hashCode() won't work the same way as with
java.util.Properties, because they are no longer inherited from Hashtable. All
you get is identity equality/hashcode.
Also note that any header comment in the .properties file will be interpreted
as
a comment attached to the first message.
Fedora Account System Username: pahuang
--
You are receiving this mail because:
You are on the CC list for the bug.
Unsubscribe from this bug https://bugzilla.redhat.com/token.cgi?t=PukszD6rfi&a=cc_unsubscribe
11 years, 1 month