java.lang.Object | +--com.ibm.commerce.programadapter.messagemapper.MessageMapperGroup
The Component which all messages will go through to be converted into a com.ibm.commerce.datatype.CommandProperty object. This is responsible for initializing all defined MessageMappers and calling the appropriate MessagMapper to convert the given object.
Field Summary | |
---|---|
static java.lang.String |
_MESSAGE_MAPPER_ID The parameter used to store the identifier of the message mapper. |
static java.lang.String |
_MESSAGE_MAPPER_NAME The parameter used to store the name of the message mapper. |
static java.lang.String |
COPYRIGHT IBM Copyright notice field. |
static java.util.Vector |
messageMapperGroup The defined message mappers. |
Constructor Summary | |
---|---|
MessageMapperGroup() Creates the Message Mapper container object. |
Method Summary | |
---|---|
void |
destroy() This destroy method will be called when the request servlet is stopped or destroyed. |
void |
enable(boolean val) This method is used to dynamically enable or disable a component. |
static
CommandProperty |
getObjectForMessage(java.lang.Object message) Will call each MessageMessage in order they were configured in the component properties and return the first non null CommandProperty object. |
static
CommandProperty |
getObjectForMessage(java.lang.Object message,
java.lang.Integer deviceFmtId) Will return the result from the specified MessageMapper which was specified by the MessageMapper Identifier. |
static
CommandProperty |
getObjectForMessage(java.lang.Object message,
java.lang.String name) Will return the result from the specified MessageMapper which was specified by the MessageMapper name. |
void |
init(org.w3c.dom.Element node) The initilization method for the component. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll,
toString, wait, wait, wait |
Field Detail |
---|
public static final java.lang.String COPYRIGHT
public static java.util.Vector messageMapperGroup
public static final java.lang.String _MESSAGE_MAPPER_NAME
public static final java.lang.String _MESSAGE_MAPPER_ID
Constructor Detail |
---|
public MessageMapperGroup()
Method Detail |
---|
public void destroy()
destroy
in interface
ComponentConfiguration
public void enable(boolean val) throws java.lang.Exception
enable
in interface
ComponentConfiguration
val
- whether to enable or disable the component.java.lang.Exception
public static CommandProperty getObjectForMessage(java.lang.Object message)
message
- the object to check if a message mapper can create a
command property representation.public static CommandProperty getObjectForMessage(java.lang.Object message, java.lang.Integer deviceFmtId)
message
- the message to convert into a command property.public static CommandProperty getObjectForMessage(java.lang.Object message, java.lang.String name)
message
- the message to convert into a command property
object.public void init(org.w3c.dom.Element node) throws java.lang.Exception
init
in interface
ComponentConfiguration
node
- a dom element node with the parameters for the
component, null if no property is presentjava.lang.Exception
- if there is a problem with
intialization.