/** * Prints a given XML element, which contains only given attributes, to a given * <code>PrintWriter</code>, maintaining a given indentation level. * * @param tag * The given XML tag. * @param attributes * The given XML element attributes. * @param oWriter * The given <code>PrintWriter</code> object. * @param level * The given indentation level (number of marginal '\t' symbols). * @throws IOException * if any I/O exception occurred. */ public static void printXMLElement(String tag, Properties attributes, PrintWriter oWriter, int level) throws IOException { printXMLElement(tag, attributes, null, oWriter, level); }
printXMLElements(tag, eValue, valueDelimiter, oWriter, level); else { printXMLElement(tag, eValue, oWriter, level); printXMLElements(tag, eValue, valueDelimiter, oWriter, level); else { printXMLElement(tag, eValue, oWriter, level);
/** * Prints a given XML element, which contains only a given string value, to a given * <code>PrintWriter</code>, maintaining a given indentation level. The string element value is * printed 'as-is' without the CDATA block. * * @param tag * The given XML tag. * @param elemValue * The given XML element value. * @param oWriter * The given <code>PrintWriter</code> object. * @param level * The given indentation level (number of marginal '\t' symbols). * @throws IOException * if any I/O exception occurred. */ public static void printXMLElement(String tag, String elemValue, PrintWriter oWriter, int level) throws IOException { printXMLElement(tag, null, elemValue, oWriter, level); }
/** * Prints a given XML element, which contains given attributes and a given string value, to a * given <code>PrintWriter</code>, maintaining a given indentation level. The string element * value (if exists) is printed 'as is' - without a CDATA section. * * @param tag * The given XML element tag. * @param attributes * The given XML element attributes. * @param elemValue * The given XML element value. * @param oWriter * The given <code>PrintWriter</code> object. * @param level * The given indentation level (number of marginal '\t' symbols). * @throws IOException * if any I/O exception occurred. */ public static void printXMLElement(String tag, Properties attributes, String elemValue, PrintWriter oWriter, int level) throws IOException { printXMLElement(tag, attributes, elemValue, false, oWriter, level, false); }
/** * Prints a given XML element, which contains only a given string value, to a given * <code>PrintWriter</code>, maintaining a given indentation level. The string element value * (if exists) is put into the CDATA block, if a given <code>boolean</code> flag is * <code>true</code>. * * @param tag * The given XML tag. * @param elemValue * The given XML element value. * @param putInCdataSection * If <code>true</code>, puts the element value in the <code>CDATA</code> section, * otherwise prints the element value without the <code>CDATA</code> section. * @param oWriter * The given <code>PrintWriter</code> object. * @param level * The given indentation level (number of marginal '\t' symbols). * @throws IOException * if any I/O exception occurred. */ public static void printXMLElement(String tag, String elemValue, boolean putInCdataSection, PrintWriter oWriter, int level) throws IOException { printXMLElement(tag, null, elemValue, putInCdataSection, oWriter, level); }
/** * Prints a given XML element, which contains given attributes and a given string value, to a * given <code>PrintWriter</code>, maintaining a given indentation level. The string element * value (if exists) is printed within or without the CDATA section, depending on a given * <code>boolean</code> flag value. * * @param tag * The given XML element tag. * @param attributes * The given XML element tag. * @param elemValue * The given XML element value. * @param putInCdataSection * If <code>true</code>, puts the element value in the <code>CDATA</code> section, * otherwise prints the element value without the <code>CDATA</code> section. * @param oWriter * The given <code>PrintWriter</code> object. * @param level * The given indentation level (number of marginal '\t' symbols). * @throws IOException * if any I/O exception occurred. */ public static void printXMLElement(String tag, Properties attributes, String elemValue, boolean putInCdataSection, PrintWriter oWriter, int level) throws IOException { printXMLElement(tag, attributes, elemValue, putInCdataSection, oWriter, level, false); }
XMLUtil.printXMLElement(tag, elemToken, oWriter, level); oWriter.println();
XMLUtil.printXMLElement(ID_TAG, insdObject.getMainComponentId(), oWriter, 2); oWriter.println(); XMLUtil.printXMLElement(NAME_TAG, insdObject.getMainComponentName(), oWriter, 2); oWriter.println(); XMLUtil.printXMLElement(DESC_TAG, insdObject.getMainComponentDesc(), oWriter, 2); oWriter.println(); XMLUtil.printXMLElement(DEPLOYMENT_TAG, insdObject.getMainComponentDeployment(), oWriter, 2); oWriter.println(); XMLUtil.printXMLElement(SERVICE_COMMAND_TAG, service.command, oWriter, 2); oWriter.println(); XMLUtil.printXMLElement(SERVICE_WORKING_DIR_TAG, service.workingDirPath, oWriter, 2); oWriter.println(); XMLUtil.printXMLElement(VALUE_TAG, arg.value, oWriter, 4); oWriter.println(); XMLUtil.printXMLElement(COMMENTS_TAG, arg.comments, oWriter, 4); oWriter.println(); String name = nameList.next(); Properties attributes = insdObject.getMainComponentNetworkParam(name); XMLUtil.printXMLElement(name, attributes, null, oWriter, 3); oWriter.println();