src/share/classes/java/util/prefs/Preferences.java

Print this page

        

@@ -132,56 +132,56 @@
  * preferences to be "imported" back into the system.  This facility
  * may be used to back up all or part of a preference tree, and
  * subsequently restore from the backup.
  *
  * <p>The XML document has the following DOCTYPE declaration:
- * <pre>
- * &lt;!DOCTYPE preferences SYSTEM "http://java.sun.com/dtd/preferences.dtd"&gt;
- * </pre>
+ * <pre>{@code
+ * <!DOCTYPE preferences SYSTEM "http://java.sun.com/dtd/preferences.dtd">
+ * }</pre>
  * Note that the system URI (http://java.sun.com/dtd/preferences.dtd) is
  * <i>not</i> accessed when exporting or importing preferences; it merely
  * serves as a string to uniquely identify the DTD, which is:
- * <pre>
- *    &lt;?xml version="1.0" encoding="UTF-8"?&gt;
+ * <pre>{@code
+ *    <?xml version="1.0" encoding="UTF-8"?>
  *
- *    &lt;!-- DTD for a Preferences tree. --&gt;
+ *    <!-- DTD for a Preferences tree. -->
  *
- *    &lt;!-- The preferences element is at the root of an XML document
- *         representing a Preferences tree. --&gt;
- *    &lt;!ELEMENT preferences (root)&gt;
- *
- *    &lt;!-- The preferences element contains an optional version attribute,
- *          which specifies version of DTD. --&gt;
- *    &lt;!ATTLIST preferences EXTERNAL_XML_VERSION CDATA "0.0" &gt
- *
- *    &lt;!-- The root element has a map representing the root's preferences
- *         (if any), and one node for each child of the root (if any). --&gt;
- *    &lt;!ELEMENT root (map, node*) &gt;
- *
- *    &lt;!-- Additionally, the root contains a type attribute, which
- *         specifies whether it's the system or user root. --&gt;
- *    &lt;!ATTLIST root
- *              type (system|user) #REQUIRED &gt;
- *
- *    &lt;!-- Each node has a map representing its preferences (if any),
- *         and one node for each child (if any). --&gt;
- *    &lt;!ELEMENT node (map, node*) &gt;
- *
- *    &lt;!-- Additionally, each node has a name attribute --&gt;
- *    &lt;!ATTLIST node
- *              name CDATA #REQUIRED &gt;
- *
- *    &lt;!-- A map represents the preferences stored at a node (if any). --&gt;
- *    &lt;!ELEMENT map (entry*) &gt;
- *
- *    &lt;!-- An entry represents a single preference, which is simply
- *          a key-value pair. --&gt;
- *    &lt;!ELEMENT entry EMPTY &gt;
- *    &lt;!ATTLIST entry
+ *    <!-- The preferences element is at the root of an XML document
+ *         representing a Preferences tree. -->
+ *    <!ELEMENT preferences (root)>
+ *
+ *    <!-- The preferences element contains an optional version attribute,
+ *          which specifies version of DTD. -->
+ *    <!ATTLIST preferences EXTERNAL_XML_VERSION CDATA "0.0" >
+ *
+ *    <!-- The root element has a map representing the root's preferences
+ *         (if any), and one node for each child of the root (if any). -->
+ *    <!ELEMENT root (map, node*) >
+ *
+ *    <!-- Additionally, the root contains a type attribute, which
+ *         specifies whether it's the system or user root. -->
+ *    <!ATTLIST root
+ *              type (system|user) #REQUIRED >
+ *
+ *    <!-- Each node has a map representing its preferences (if any),
+ *         and one node for each child (if any). -->
+ *    <!ELEMENT node (map, node*) >
+ *
+ *    <!-- Additionally, each node has a name attribute -->
+ *    <!ATTLIST node
+ *              name CDATA #REQUIRED >
+ *
+ *    <!-- A map represents the preferences stored at a node (if any). -->
+ *    <!ELEMENT map (entry*) >
+ *
+ *    <!-- An entry represents a single preference, which is simply
+ *          a key-value pair. -->
+ *    <!ELEMENT entry EMPTY >
+ *    <!ATTLIST entry
  *              key   CDATA #REQUIRED
- *              value CDATA #REQUIRED &gt;
- * </pre>
+ *              value CDATA #REQUIRED >
+ * }</pre>
  *
  * Every <tt>Preferences</tt> implementation must have an associated {@link
  * PreferencesFactory} implementation.  Every Java(TM) SE implementation must provide
  * some means of specifying which <tt>PreferencesFactory</tt> implementation
  * is used to generate the root preferences nodes.  This allows the

@@ -1159,13 +1159,13 @@
      * Emits on the specified output stream an XML document representing all
      * of the preferences contained in this node (but not its descendants).
      * This XML document is, in effect, an offline backup of the node.
      *
      * <p>The XML document will have the following DOCTYPE declaration:
-     * <pre>
-     * &lt;!DOCTYPE preferences SYSTEM "http://java.sun.com/dtd/preferences.dtd"&gt;
-     * </pre>
+     * <pre>{@code
+     * <!DOCTYPE preferences SYSTEM "http://java.sun.com/dtd/preferences.dtd">
+     * }</pre>
      * The UTF-8 character encoding will be used.
      *
      * <p>This method is an exception to the general rule that the results of
      * concurrently executing multiple methods in this class yields
      * results equivalent to some serial execution.  If the preferences

@@ -1190,13 +1190,13 @@
      * Emits an XML document representing all of the preferences contained
      * in this node and all of its descendants.  This XML document is, in
      * effect, an offline backup of the subtree rooted at the node.
      *
      * <p>The XML document will have the following DOCTYPE declaration:
-     * <pre>
-     * &lt;!DOCTYPE preferences SYSTEM "http://java.sun.com/dtd/preferences.dtd"&gt;
-     * </pre>
+     * <pre>{@code
+     * <!DOCTYPE preferences SYSTEM "http://java.sun.com/dtd/preferences.dtd">
+     * }</pre>
      * The UTF-8 character encoding will be used.
      *
      * <p>This method is an exception to the general rule that the results of
      * concurrently executing multiple methods in this class yields
      * results equivalent to some serial execution.  If the preferences

@@ -1226,13 +1226,13 @@
      * originally came from a different user's preference tree).  If any of
      * the preferences described by the document inhabit preference nodes that
      * do not exist, the nodes will be created.
      *
      * <p>The XML document must have the following DOCTYPE declaration:
-     * <pre>
-     * &lt;!DOCTYPE preferences SYSTEM "http://java.sun.com/dtd/preferences.dtd"&gt;
-     * </pre>
+     * <pre>{@code
+     * <!DOCTYPE preferences SYSTEM "http://java.sun.com/dtd/preferences.dtd">
+     * }</pre>
      * (This method is designed for use in conjunction with
      * {@link #exportNode(OutputStream)} and
      * {@link #exportSubtree(OutputStream)}.
      *
      * <p>This method is an exception to the general rule that the results of