|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectcom.cri.xcat.api.helpers.XcatUtilities
public class XcatUtilities
Contains various helper functions that are useful in dealing with xCAT communications.
| Constructor Summary | |
|---|---|
XcatUtilities()
|
|
| Method Summary | |
|---|---|
static org.w3c.dom.Document |
createXmlDocument(java.util.Map<java.lang.String,java.lang.Object> map)
Creates an XML document in the format that xcatd would expect from the input map. |
static boolean |
isEmpty(java.lang.String str)
Returns true if the string is null or an empty string. |
static void |
xmlToOutputStream(org.w3c.dom.Document dom,
java.io.OutputStream stream)
Takes an XML document and sends it to the output stream in a way that xcatd would expect. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public XcatUtilities()
| Method Detail |
|---|
public static org.w3c.dom.Document createXmlDocument(java.util.Map<java.lang.String,java.lang.Object> map)
throws javax.xml.parsers.ParserConfigurationException
Iterable (a collection of some kind), then each
value inside the collection gets a separate tag with the text content
inside set to the String value of the item.
map - The map that will be used to create the XML
javax.xml.parsers.ParserConfigurationException
public static void xmlToOutputStream(org.w3c.dom.Document dom,
java.io.OutputStream stream)
throws javax.xml.transform.TransformerException
dom - the XML document that will be sent to the output stream.stream - the output stream from the socket that would be the connection
to xcatd
javax.xml.transform.TransformerExceptionpublic static boolean isEmpty(java.lang.String str)
str - the string to check.
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||