|
QJCC homepage | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object biz.chitec.quarterback.util.OrderedPropertyStorer
Helper class to store contents of a properties list in alphabetical order. Needed for CVS controlled resources to let CVS having a chance of getting changes sorted out. For the same reason the class offers the possibility not to store the timestamp in the header of the properties file.
Inspired by some code of Properties.java as that one is somehow brain-dead when it comes to storing its contents ordered...
Field Summary | |
private boolean |
iscvs
|
private boolean |
isunixlinefeed
|
private static OrderedPropertyStorer |
singleton
|
Constructor Summary | |
OrderedPropertyStorer(boolean iscvsx,
boolean isunixlinefeedx)
This class is non-instanciable. |
Method Summary | |
boolean |
isCVS()
|
boolean |
isDefaultCVS()
|
boolean |
isDefaultUnixLineFeed()
|
boolean |
isUnixLineFeed()
|
private java.lang.String |
saveConvert(java.lang.String theString,
boolean escapeSpace)
Converts unicodes to encoded \uxxxx and writes out any special characters with a preceding slash. |
void |
setCVS(boolean iscvs)
|
void |
setDefaultCVS(boolean iscvs)
|
void |
setDefaultUnixLineFeed(boolean b)
|
void |
setUnixLineFeed(boolean b)
|
void |
store(java.util.Properties props,
java.io.OutputStream out,
java.lang.String header)
Writes a Properties' list ordered into the given stream. |
static void |
storeDefault(java.util.Properties props,
java.io.OutputStream out,
java.lang.String header)
Writes a Properties' list ordered into the given stream. |
private char |
toHex(int nibble)
Convert a nibble to a hex character |
private void |
writeln(java.io.BufferedWriter bw,
java.lang.String s)
Description of the Method |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
private static OrderedPropertyStorer singleton
private boolean iscvs
private boolean isunixlinefeed
Constructor Detail |
public OrderedPropertyStorer(boolean iscvsx, boolean isunixlinefeedx)
Method Detail |
public void setCVS(boolean iscvs)
public boolean isCVS()
public void setUnixLineFeed(boolean b)
public boolean isUnixLineFeed()
public void setDefaultCVS(boolean iscvs)
public boolean isDefaultCVS()
public void setDefaultUnixLineFeed(boolean b)
public boolean isDefaultUnixLineFeed()
private char toHex(int nibble)
nibble
- the nibble to convert.
private java.lang.String saveConvert(java.lang.String theString, boolean escapeSpace)
theString
- Description of the ParameterescapeSpace
- Description of the Parameter
public void store(java.util.Properties props, java.io.OutputStream out, java.lang.String header) throws java.io.IOException
out
- an output stream.header
- a description of the property list.props
- Description of the Parameter
java.io.IOException
- if writing this property list to the specified output stream throws an
IOException .private void writeln(java.io.BufferedWriter bw, java.lang.String s) throws java.io.IOException
bw
- Description of the Parameters
- Description of the Parameter
java.io.IOException
- Description of the Exceptionpublic static void storeDefault(java.util.Properties props, java.io.OutputStream out, java.lang.String header) throws java.io.IOException
out
- an output stream.header
- a description of the property list.props
- Description of the Parameter
java.io.IOException
- if writing this property list to the specified output stream throws an
IOException .
|
QJCC homepage | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |