com.xebialabs.deployit.booter.local.utils
Class XmlUtils

java.lang.Object
  extended by com.xebialabs.deployit.booter.local.utils.XmlUtils

public class XmlUtils
extends java.lang.Object


Nested Class Summary
static interface XmlUtils.Closure<E>
           
 
Constructor Summary
XmlUtils()
           
 
Method Summary
static java.util.Iterator<org.w3c.dom.Element> childByName(org.w3c.dom.Element element, com.google.common.base.Predicate<java.lang.String> matcher)
           
static java.lang.Iterable<org.w3c.dom.Element> childrenByName(org.w3c.dom.Element element, com.google.common.base.Predicate<java.lang.String> matcher)
           
static
<E> void
forEach(java.util.Iterator<E> iterator, XmlUtils.Closure<E> closure)
           
static boolean getOptionalBooleanAttribute(org.w3c.dom.Element element, java.lang.String attributeName, boolean defaultValue)
           
static java.lang.String getOptionalStringAttribute(org.w3c.dom.Element element, java.lang.String attributeName, java.lang.String defaultValue)
           
static com.xebialabs.deployit.plugin.api.reflect.Type getOptionalTypeAttribute(org.w3c.dom.Element element, java.lang.String attributeName)
           
static com.xebialabs.deployit.plugin.api.reflect.Type getOptionalTypeAttribute(org.w3c.dom.Element element, java.lang.String attributeName, com.xebialabs.deployit.plugin.api.reflect.Type defaultValue)
           
static java.lang.String getRequiredStringAttribute(org.w3c.dom.Element element, java.lang.String attributeName)
           
static java.lang.String getRequiredStringAttribute(org.w3c.dom.Element element, java.lang.String attributeName, java.lang.String additionalMessage)
           
static com.xebialabs.deployit.plugin.api.reflect.Type getRequiredTypeAttribute(org.w3c.dom.Element element, java.lang.String attributeName)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

XmlUtils

public XmlUtils()
Method Detail

getRequiredStringAttribute

public static java.lang.String getRequiredStringAttribute(org.w3c.dom.Element element,
                                                          java.lang.String attributeName)

getRequiredStringAttribute

public static java.lang.String getRequiredStringAttribute(org.w3c.dom.Element element,
                                                          java.lang.String attributeName,
                                                          java.lang.String additionalMessage)

getRequiredTypeAttribute

public static com.xebialabs.deployit.plugin.api.reflect.Type getRequiredTypeAttribute(org.w3c.dom.Element element,
                                                                                      java.lang.String attributeName)

getOptionalTypeAttribute

public static com.xebialabs.deployit.plugin.api.reflect.Type getOptionalTypeAttribute(org.w3c.dom.Element element,
                                                                                      java.lang.String attributeName,
                                                                                      com.xebialabs.deployit.plugin.api.reflect.Type defaultValue)

getOptionalTypeAttribute

public static com.xebialabs.deployit.plugin.api.reflect.Type getOptionalTypeAttribute(org.w3c.dom.Element element,
                                                                                      java.lang.String attributeName)

getOptionalBooleanAttribute

public static boolean getOptionalBooleanAttribute(org.w3c.dom.Element element,
                                                  java.lang.String attributeName,
                                                  boolean defaultValue)

getOptionalStringAttribute

public static java.lang.String getOptionalStringAttribute(org.w3c.dom.Element element,
                                                          java.lang.String attributeName,
                                                          java.lang.String defaultValue)

childrenByName

public static java.lang.Iterable<org.w3c.dom.Element> childrenByName(org.w3c.dom.Element element,
                                                                     com.google.common.base.Predicate<java.lang.String> matcher)

childByName

public static java.util.Iterator<org.w3c.dom.Element> childByName(org.w3c.dom.Element element,
                                                                  com.google.common.base.Predicate<java.lang.String> matcher)

forEach

public static <E> void forEach(java.util.Iterator<E> iterator,
                               XmlUtils.Closure<E> closure)