src/share/classes/sun/util/xml/XMLUtils.java

Print this page

        

*** 21,33 **** * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA * or visit www.oracle.com if you need additional information or have any * questions. */ ! package java.util; import java.io.*; import org.xml.sax.*; import org.xml.sax.helpers.*; import org.w3c.dom.*; import javax.xml.parsers.*; import javax.xml.transform.*; --- 21,34 ---- * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA * or visit www.oracle.com if you need additional information or have any * questions. */ ! package sun.util.xml; import java.io.*; + import java.util.*; import org.xml.sax.*; import org.xml.sax.helpers.*; import org.w3c.dom.*; import javax.xml.parsers.*; import javax.xml.transform.*;
*** 40,50 **** * when Properties is loaded. * * @author Michael McCloskey * @since 1.3 */ ! class XMLUtils { // XML loading and saving methods for Properties // The required DTD URI for exported properties private static final String PROPS_DTD_URI = --- 41,51 ---- * when Properties is loaded. * * @author Michael McCloskey * @since 1.3 */ ! public class XMLUtils { // XML loading and saving methods for Properties // The required DTD URI for exported properties private static final String PROPS_DTD_URI =
*** 64,74 **** /** * Version number for the format of exported properties files. */ private static final String EXTERNAL_XML_VERSION = "1.0"; ! static void load(Properties props, InputStream in) throws IOException, InvalidPropertiesFormatException { Document doc = null; try { doc = getLoadingDoc(in); --- 65,75 ---- /** * Version number for the format of exported properties files. */ private static final String EXTERNAL_XML_VERSION = "1.0"; ! public static void load(Properties props, InputStream in) throws IOException, InvalidPropertiesFormatException { Document doc = null; try { doc = getLoadingDoc(in);
*** 118,128 **** props.setProperty(entry.getAttribute("key"), val); } } } ! static void save(Properties props, OutputStream os, String comment, String encoding) throws IOException { DocumentBuilderFactory dbf = DocumentBuilderFactory.newInstance(); DocumentBuilder db = null; --- 119,129 ---- props.setProperty(entry.getAttribute("key"), val); } } } ! public static void save(Properties props, OutputStream os, String comment, String encoding) throws IOException { DocumentBuilderFactory dbf = DocumentBuilderFactory.newInstance(); DocumentBuilder db = null;