com.free2be.dimensions.device.simple
Class SimpleDeviceComponent
java.lang.Object
com.free2be.dimensions.device.simple.SimpleDeviceComponent
- All Implemented Interfaces:
- DeviceComponent, java.io.Serializable
- Direct Known Subclasses:
- SimpleAudio, SimpleBrowser, SimpleDevice, SimpleHardware, SimpleImage, SimpleJava, SimpleNetwork, SimpleSoftware, SimpleWapBrowser
public abstract class SimpleDeviceComponent
- extends java.lang.Object
- implements DeviceComponent
- See Also:
- Serialized Form
Method Summary |
protected void |
assignEndTag(java.lang.StringBuffer xml,
java.lang.String propertyName)
|
protected void |
assignNewline(java.lang.StringBuffer xml,
java.lang.String indent)
|
protected void |
assignStartTag(java.lang.StringBuffer xml,
java.lang.String propertyName)
converts the property name to a start tag and adds it ot the xml. |
java.lang.String |
getAsXml()
Ideally this will always return the CC/PP representation of this device, but until then:
If derived from a valid CC/PP (like UAProf) document then that document will be returned as formatted string. |
protected java.lang.String |
getAsXml(java.lang.String originalIndent,
java.lang.String indent)
|
abstract java.lang.String |
getPropertyName()
Each implementation must return a xml representation (name) that best describes it. |
java.lang.String |
getSimpleXml()
|
static void |
main(java.lang.String[] args)
|
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
LESS_THAN
protected static final char LESS_THAN
- See Also:
- Constant Field Values
GREATER_THAN
protected static final char GREATER_THAN
- See Also:
- Constant Field Values
END_TAG_INDICATOR
protected static final char END_TAG_INDICATOR
- See Also:
- Constant Field Values
SimpleDeviceComponent
public SimpleDeviceComponent()
getAsXml
public java.lang.String getAsXml()
- Description copied from interface:
DeviceComponent
- Ideally this will always return the CC/PP representation of this device, but until then:
-
If derived from a valid CC/PP (like UAProf) document then that document will be returned as formatted string.
-
If not derived from a valid document, this will return simple xml from a bean crawler until a bean/xml mapper
is used to display the device as valid CC/PP document.
- Specified by:
getAsXml
in interface DeviceComponent
getSimpleXml
public java.lang.String getSimpleXml()
getAsXml
protected java.lang.String getAsXml(java.lang.String originalIndent,
java.lang.String indent)
assignNewline
protected void assignNewline(java.lang.StringBuffer xml,
java.lang.String indent)
assignStartTag
protected void assignStartTag(java.lang.StringBuffer xml,
java.lang.String propertyName)
- converts the property name to a start tag and adds it ot the xml.
assignEndTag
protected void assignEndTag(java.lang.StringBuffer xml,
java.lang.String propertyName)
main
public static void main(java.lang.String[] args)
getPropertyName
public abstract java.lang.String getPropertyName()
- Each implementation must return a xml representation (name) that best describes it.