public class POBNodeBuilder
extends java.lang.Object
| Constructor and Description |
|---|
POBNodeBuilder(org.w3c.dom.Node node)
Constructor to instantiate the class object with provided argument
|
| Modifier and Type | Method and Description |
|---|---|
java.lang.String |
getAttributeValue(java.lang.String attPath)
Returns the value of current node attribute for provided attribute name
|
org.w3c.dom.Node |
getNode(java.lang.String path)
Retrieves a sub-node at provide xpath and returns it.
|
java.lang.String |
getNodeName()
Returns the name of current node
|
<T extends POBXMLNodeListener> |
getNodeObject(java.lang.String path,
java.lang.Class<T> elementType)
Creates and returns an instance of provided class type for provided xPath
|
java.lang.String |
getNodeValue()
Returns the value of current node
|
java.lang.String |
getNodeValue(java.lang.String path)
Returns the value of sub-node
|
<T extends POBXMLNodeListener> |
getObjectList(java.lang.String path,
java.lang.Class<T> elementType)
Creates and returns a list of provided class type for provided xPath
|
java.util.List<java.lang.String> |
getStringList(java.lang.String path)
Creates and returns a list of node values with provided xPath
|
public POBNodeBuilder(@Nullable
org.w3c.dom.Node node)
node - xml node@Nullable public java.lang.String getNodeName()
@Nullable public java.lang.String getNodeValue()
@Nullable public <T extends POBXMLNodeListener> java.util.List<T> getObjectList(@NonNull java.lang.String path, @NonNull java.lang.Class<T> elementType)
T - Any model class from Vast module like POBTracking, POBMediaFile, POBCompanion,
POBAdVerification etcpath - sub-node relative xpath of sub-node from current nodeelementType - class of which instance to be created@Nullable
public java.util.List<java.lang.String> getStringList(@NonNull
java.lang.String path)
path - sub-node relative xpath of sub-node from current node@Nullable
public java.lang.String getNodeValue(@NonNull
java.lang.String path)
path - sub-node relative xpath of sub-node from current node@Nullable
public org.w3c.dom.Node getNode(@NonNull
java.lang.String path)
path - relative xpath of sub-node from current node@Nullable public <T extends POBXMLNodeListener> T getNodeObject(@NonNull java.lang.String path, @NonNull java.lang.Class<T> elementType)
T - Any model class from Vast module like POBResource, POBLinear, POBNonLinear etcpath - sub-node relative xpath of sub-node from current nodeelementType - class of which list to be created@Nullable
public java.lang.String getAttributeValue(@NonNull
java.lang.String attPath)
attPath - attribute xpath from current node