public class MTree extends MNode
MTree
class provides two types of structures for data representation.
MNode
or an MTree
. This structure
is for data that is to be sent in AERV or RV message format. To add XML text to an MTree
, call setTextBody(String)
.
m_NodeImpl
Constructor and Description |
---|
MTree(java.lang.Object jmsMessage)
Deprecated.
|
MTree(java.lang.String name)
Create an
MTree instance in AERV message format. |
MTree(java.lang.String name,
int format)
Constructor for creating
MTree instances of specified message format. |
MTree(java.lang.String p_name,
java.lang.Object p_data)
internal use only - do not document
|
MTree(com.tibco.tibrv.TibrvMsg p_msg,
boolean p_copy)
Deprecated.
|
Modifier and Type | Method and Description |
---|---|
void |
append(MNode node)
Deprecated.
in TIBCO Adapter SDK 5.0.0
|
void |
append(java.lang.String name,
boolean data)
Add the given node to the list of children of this tree node.
|
void |
append(java.lang.String name,
byte data)
Add the given data to the list of children of this tree node.
|
void |
append(java.lang.String name,
double data)
Add the given node to the list of children of this tree node.
|
void |
append(java.lang.String name,
float data)
Add the given node to the list of children of this tree node.
|
void |
append(java.lang.String name,
int data)
Add the given node to the list of children of this tree node.
|
void |
append(java.lang.String name,
long data)
Add the given node to the list of children of this tree node.
|
void |
append(java.lang.String name,
java.lang.Object value)
Add the given node to the list of children of this tree node.
|
void |
append(java.lang.String name,
short data)
Add the given node to the list of children of this tree node.
|
void |
clear()
Deprecated.
|
boolean |
containsNode(java.lang.String name)
Return
true if there is a child node with the given name. |
protected void |
finalize() |
MGUID |
getAssignMsgGUID()
Deprecated.
Internal use only
|
MClassRegistry |
getClassRegistry()
Deprecated.
Internal use only - IM/BW
|
int |
getFieldCount()
Deprecated.
Internal use only
|
java.lang.String |
getFieldName(int p_index)
Deprecated.
Internal use only
|
java.lang.String |
getJmsProperty(java.lang.String sPropertyName)
Gets the Jms properties
|
java.lang.Object |
getJmsPropertyObject(java.lang.String p_propName)
internal use only - do not document
|
int |
getMessageFormat()
Retrieve the message format informatino for this
MTree instances. |
MNode |
getNode(java.lang.String name)
Deprecated.
|
java.util.Enumeration |
getNodes()
Deprecated.
|
MNode |
getProperty(java.lang.String p_propName)
Deprecated.
internal use only - do not document
|
short |
getRepresentationEncoding()
Deprecated.
|
short |
getRepresentationFormat()
Deprecated.
|
short |
getRepresentationType()
Deprecated.
|
short |
getRepresentationVersion()
Deprecated.
|
java.lang.String |
getTextBody()
Retrieves the XML string for JMS message.
|
MTrackingInfo |
getTrackingInfo()
Retrieve the tracking information from the
MTree object. |
java.lang.Object |
getUnderlyingMsg()
Return the underlying object that encapsulate this
MTree . |
java.lang.Object |
getValue(java.lang.String name)
Return the value of the node whose name is given.
|
boolean |
hasTrackingInfo()
Deprecated.
|
java.util.Enumeration |
newPropertyEnumerator()
Deprecated.
|
void |
replaceContents(MTree tree)
Replace the contents of this tree with the contents of the tree specified by the tree parameter.
|
void |
setAssignMsgGUID(MGUID p_guid)
Deprecated.
|
void |
setClassRegistry(MClassRegistry classRegistry)
Deprecated.
Internal use only
|
void |
setJmsProperty(java.lang.String propertyName,
boolean propertyValue)
Sets Jms properties
|
void |
setJmsProperty(java.lang.String propertyName,
char propertyValue)
Sets Jms properties
|
void |
setJmsProperty(java.lang.String propertyName,
double propertyValue)
Sets Jms properties
|
void |
setJmsProperty(java.lang.String propertyName,
float propertyValue)
Sets Jms properties
|
void |
setJmsProperty(java.lang.String propertyName,
int propertyValue)
Sets Jms properties
|
void |
setJmsProperty(java.lang.String propertyName,
long propertyValue)
Sets Jms properties
|
void |
setJmsProperty(java.lang.String propertyName,
short propertyValue)
Sets Jms properties
|
void |
setJmsProperty(java.lang.String sPropertyName,
java.lang.String sPropertyValue)
Sets Jms properties
|
void |
setProperty(java.lang.String p_propName,
MNode p_node)
Deprecated.
|
void |
setProperty(java.lang.String sPropertyName,
java.lang.String sPropertyValue)
Deprecated.
Internal use only
|
void |
setRepresentationEncoding(short p_encoding)
Deprecated.
|
void |
setRepresentationFormat(short p_format)
Deprecated.
|
void |
setRepresentationType(short p_type)
Deprecated.
|
void |
setRepresentationVersion(short p_version)
Deprecated.
Possible values for rep. type are 1 for RVMsg & 10 for XML
10 = Wireformat version2.0
30 = Wireformat version 3.0
|
void |
setTextBody(java.lang.String xmlText)
Set XML text to this tree.
|
void |
setTrackingInfo(MTrackingInfo data)
Forward the tracking info to a new
MTree object. |
com.tibco.tibrv.TibrvMsg |
to_tibrvMsg()
Get the underlying RV transport message
|
java.lang.String |
toString()
Return the string representation of this MTree
|
void |
use_tibamxMsg(AmxMessage inMsg) |
void |
use_tibrvMsg(com.tibco.tibrv.TibrvMsg msg)
Set the underlying RV transport message
|
getData, getIdAsString, getName, setNodeImpl
public MTree(java.lang.String name)
MTree
instance in AERV message format.name
- Required parameter specifying the name of the MTree
to create.public MTree(java.lang.String name, int format)
MTree
instances of specified message format. This constructor instantiates
a MTree
object with the specified name.name
- Required parameter specifying the name of the MTree
to create.format
- Required parameter specifying the message format of the MTree
to create.
Valid message format values are
MMessageFormat.AERV
- for AERv message format
MMessageFormat.RV
- for Rv message format
MMessageFormat.XMLJMS
- for JMS XML message format
MMessageFormat.XMLRV
- for RV XML message format
public MTree(java.lang.String p_name, java.lang.Object p_data)
public MTree(com.tibco.tibrv.TibrvMsg p_msg, boolean p_copy) throws MException
MException
public MTree(java.lang.Object jmsMessage)
public void append(MNode node) throws MException
MException
public void append(java.lang.String name, java.lang.Object value) throws MException
MNode
, MTree
, Short
, Integer
, Long
,
Float
, Double
, String
, Byte
, Boolean
MTree
field names may not contain special (non-alphanumeric) characters. The
null character is not valid in a field name.
This only applies to AERV and RV message format. No operation is performed on XMLJMS and XMLRV message format.
name
- Name of the node (or tree) to appendvalue
- MTree
, a subtree is added; the name of the
root of the subtree is the specified name
.MNode
, the node value is extracted and appended
with the name specified by name
. MException
public void append(java.lang.String name, boolean data) throws MException
This only applies to AERV and RV message format. No operation is performed on XMLJMS and XMLRV message format.
name
- Name of the node (or tree) to append.data
- Data to append.MException
append(String, Object)
public void append(java.lang.String name, byte data) throws MException
This only applies to AERV and RV message format. No operation is performed on XMLJMS and XMLRV message format.
name
- Name of the node (or tree) to append.data
- Data to append.MException
append(String, Object)
public void append(java.lang.String name, short data) throws MException
This only applies to AERV and RV message format. No operation is performed on XMLJMS and XMLRV message format.
name
- Name of the node (or tree) to append.data
- Data to append.MException
append(String, Object)
public void append(java.lang.String name, int data) throws MException
This only applies to AERV and RV message format. No operation is performed on XMLJMS and XMLRV message format.
name
- Name of the node (or tree) to append.data
- Data to append.MException
append(String, Object)
public void append(java.lang.String name, long data) throws MException
This only applies to AERV and RV message format. No operation is performed on XMLJMS and XMLRV message format.
name
- Name of the node (or tree) to append.data
- Data to append.MException
append(String, Object)
public void append(java.lang.String name, float data) throws MException
This only applies to AERV and RV message format. No operation is performed on XMLJMS and XMLRV message format.
name
- Name of the node (or tree) to append.data
- Data to append.MException
append(String, Object)
public void append(java.lang.String name, double data) throws MException
This only applies to AERV and RV message format. No operation is performed on XMLJMS and XMLRV message format.
name
- Name of the node (or tree) to append.data
- Data to append.MException
append(String, Object)
public MNode getNode(java.lang.String name)
public java.lang.Object getValue(java.lang.String name)
getNode(nodeName)
.public java.util.Enumeration getNodes()
public boolean containsNode(java.lang.String name)
true
if there is a child node with the given name.name
- Name of the node you are looking for.public void setTrackingInfo(MTrackingInfo data)
MTree
object.
MTrackingInfo.addApplicationInfo()
must
be called before tracking data is set.
data
- The information to forward.getTrackingInfo()
public MTrackingInfo getTrackingInfo()
MTree
object.
If there isnt any tracking data available, create a new tracking data with "source undefined" as tracking information.
setTrackingInfo(MTrackingInfo)
public java.lang.String toString()
public int getMessageFormat()
MTree
instances.MMessageFormat.AERV
- for AERv message format
MMessageFormat.RV
- for Rv message format
MMessageFormat.XMLJMS
- for JMS XML message format
MMessageFormat.XMLRV
- for RV XML message formatpublic void setTextBody(java.lang.String xmlText) throws MException
xmlText
- XML text to be set to this tree.MException
public java.lang.String getTextBody() throws MException
MException
public void replaceContents(MTree tree)
public void setRepresentationEncoding(short p_encoding)
public short getRepresentationEncoding()
public void setRepresentationType(short p_type)
Possible values for rep. type are 1 for RVMsg & 10 for XML
public short getRepresentationType()
public void setRepresentationFormat(short p_format)
public short getRepresentationFormat()
public void setRepresentationVersion(short p_version)
public short getRepresentationVersion()
public void setProperty(java.lang.String p_propName, MNode p_node)
public void setJmsProperty(java.lang.String propertyName, boolean propertyValue)
propertyName
- Name of the property to be setpropertyValue
- boolean value of the property to be setpublic void setJmsProperty(java.lang.String propertyName, char propertyValue)
propertyName
- Name of the property to be setpropertyValue
- char value of the property to be setpublic void setJmsProperty(java.lang.String propertyName, double propertyValue)
propertyName
- Name of the property to be setpropertyValue
- double value of the property to be setpublic void setJmsProperty(java.lang.String propertyName, float propertyValue)
propertyName
- Name of the property to be setpropertyValue
- float value of the property to be setpublic void setJmsProperty(java.lang.String propertyName, int propertyValue)
propertyName
- Name of the property to be setpropertyValue
- int value of the property to be setpublic void setJmsProperty(java.lang.String propertyName, long propertyValue)
propertyName
- Name of the property to be setpropertyValue
- long value of the property to be setpublic void setJmsProperty(java.lang.String propertyName, short propertyValue)
propertyName
- Name of the property to be setpropertyValue
- short value of the property to be setpublic void setJmsProperty(java.lang.String sPropertyName, java.lang.String sPropertyValue)
sPropertyName
- Name of the property to be setsPropertyValue
- Value of the property to be setpublic void setProperty(java.lang.String sPropertyName, java.lang.String sPropertyValue)
public java.lang.String getJmsProperty(java.lang.String sPropertyName)
sPropertyName
- Name of the propertypublic java.lang.Object getJmsPropertyObject(java.lang.String p_propName)
public MNode getProperty(java.lang.String p_propName)
public java.util.Enumeration newPropertyEnumerator()
protected void finalize() throws java.lang.Throwable
public boolean hasTrackingInfo()
public com.tibco.tibrv.TibrvMsg to_tibrvMsg()
public java.lang.Object getUnderlyingMsg()
MTree
.
The object returned could be one of the following:
public void setAssignMsgGUID(MGUID p_guid)
public MGUID getAssignMsgGUID()
public int getFieldCount()
public java.lang.String getFieldName(int p_index)
public void use_tibrvMsg(com.tibco.tibrv.TibrvMsg msg)
msg
- TibrvMsg to use, refer to RV API docpublic void clear()
public void setClassRegistry(MClassRegistry classRegistry)
public MClassRegistry getClassRegistry()
public void use_tibamxMsg(AmxMessage inMsg)