Package com.sforce.ws.bind
Class XmlObjectWrapper
- java.lang.Object
-
- com.sforce.ws.bind.XmlObject
-
- com.sforce.ws.bind.XmlObjectWrapper
-
-
Constructor Summary
Constructors Constructor Description XmlObjectWrapper(XMLizable xmlizable)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description XmlObjectaddField(String name, Object value)XMLizableasTyped()Because we create complex types as subclasses of XMLizable instead of XmlObject (and we don't want to change interfaces), this method will return this as the complex type subclass of XMLizable, if this represents a complex type.XmlObjectgetChild(String name)Iterator<XmlObject>getChildren()Iterator<XmlObject>getChildren(String name)ObjectgetField(String name)QNamegetName()QNamegetXmlType()booleanhasChildren()voidload(XmlInputStream in, TypeMapper typeMapper)load the fileds/children from the specified xml streambooleanremoveField(String name)voidsetDefaultNamespace(String namespace)XmlObjectsetField(String name, Object value)voidsetName(QName name)StringtoString()voidwrite(QName element, XmlOutputStream out, TypeMapper typeMapper)write this instace as xml.-
Methods inherited from class com.sforce.ws.bind.XmlObject
cloneFrom, evaluate, getTypedChildren, getValue, loadAfterStartTag, loadStartTag, setValue
-
-
-
-
Constructor Detail
-
XmlObjectWrapper
public XmlObjectWrapper(XMLizable xmlizable)
-
-
Method Detail
-
asTyped
public XMLizable asTyped()
Description copied from class:XmlObjectBecause we create complex types as subclasses of XMLizable instead of XmlObject (and we don't want to change interfaces), this method will return this as the complex type subclass of XMLizable, if this represents a complex type. If it does not, it will simply return this.
-
getChildren
public Iterator<XmlObject> getChildren()
- Overrides:
getChildrenin classXmlObject
-
getChildren
public Iterator<XmlObject> getChildren(String name)
- Overrides:
getChildrenin classXmlObject
-
getXmlType
public QName getXmlType()
- Overrides:
getXmlTypein classXmlObject
-
hasChildren
public boolean hasChildren()
- Overrides:
hasChildrenin classXmlObject
-
load
public void load(XmlInputStream in, TypeMapper typeMapper) throws IOException, ConnectionException
Description copied from interface:XMLizableload the fileds/children from the specified xml stream- Specified by:
loadin interfaceXMLizable- Overrides:
loadin classXmlObject- Parameters:
in- xml input stream from which the data is readtypeMapper- type mapper to be used- Throws:
IOException- failed to read xmlConnectionException- failed to read/parser/bind xml
-
removeField
public boolean removeField(String name)
- Overrides:
removeFieldin classXmlObject
-
setDefaultNamespace
public void setDefaultNamespace(String namespace)
- Overrides:
setDefaultNamespacein classXmlObject
-
write
public void write(QName element, XmlOutputStream out, TypeMapper typeMapper) throws IOException
Description copied from interface:XMLizablewrite this instace as xml.- Specified by:
writein interfaceXMLizable- Overrides:
writein classXmlObject- Parameters:
element- xml element nameout- xml output streamtypeMapper- type mapper to be used- Throws:
IOException- failed to write xml
-
-