THE PACKAGE JAVA.UTIL
java.util.Properties
21.6
the key is skipped; if the first non whitespace character after the key is
=
 or
:
, then
it is ignored and any whitespace characters after it are also skipped. All remaining
characters on the line become part of the associated element string. Within the ele 
ment string (but not the key), the ASCII escape sequences
\t
,
\n
,
\r
,
\\
,
\"
,
\'
,
\
(a backslash and a space), and
\u
xxxx
 are recognized and converted to single
characters. Moreover, if the last character on the line is
\
, then the next line is
treated as a continuation of the current line; the
\
 and line terminator are simply
discarded, and any leading whitespace characters on the continuation line are also
discarded and are not part of the element string.
As an example, each of the following four lines specifies the key
"Truth"
 and
the associated element value
"Beauty"
:
Truth Beauty
Truth = Beauty
Truth:Beauty
Truth
:Beauty
As another example, the following three lines specify a single property:
fruits
apple, banana, pear, \
cantaloupe, watermelon, \
kiwi, mango
The key is
"fruit"
 and the associated element is:
"apple, banana, pear, cantaloupe, watermelon, kiwi, mango"
Note that a space appears before each
\
 so that a space will appear after each
comma in the final result; the
\
, line terminator, and leading whitespace on the
continuation line are merely discarded and are
not
 replaced by one or more other
characters.
As a third example, the line:
cheeses
specifies that the key is
"cheeses"
 and the associated element is the empty string.
21.6.8
public void save(OutputStream out, String header)
All the properties (key and element pairs) in this
Properties
 table are written to
the output stream:
Runtime.getRuntime().getLocalizedOutputStream(out)
in a format suitable for loading into a
Properties
 table using the
load
 method
( 21.6.7). See the
getLocalizedOutputStream
 method of
Runtime
( 20.16.16).
641






footer




 

 

 

 

 Home | About Us | Network | Services | Support | FAQ | Control Panel | Order Online | Sitemap | Contact

java hosting

 

Our partners: PHP: Hypertext Preprocessor Best Web Hosting Java Web Hosting Inexpensive Web Hosting  Jsp Web Hosting

Cheapest Web Hosting Jsp Hosting Cheap Hosting

Visionwebhosting.net Business web hosting division of Web Design Plus. All rights reserved