com.ibm.websphere.sca.mq.data
Interface MQHeaderDataBinding
- public interface MQHeaderDataBinding
- extends commonj.connector.runtime.DataBinding
This interface is an extension of commonj.connector.runtime.DataBinding, and presents a WMQ-specific view which should be implemented for use in WMQ Exports and Imports specifically for support of WMQ headers.
It exposes methods which read and write a WMQ header to and from a WMQ message, as well as exporting which format of WMQ message is supported, and the associated control data: CCSID, encoding and format.
DataBinding
Field Summary
Modifier and Type | Field and Description |
---|---|
|
COPYRIGHT
|
Method Summary
Modifier and Type | Method and Description |
---|---|
|
getNextCCSID()
Called by the runtime after the
read method and
used to "unchain" the WMQ header context chaining.
|
|
getNextEncoding()
Called by the runtime after the
read method and
used to "unchain" the WMQ header context chaining.
|
|
getNextFormat()
Called by the runtime after the
read method and
used to "unchain" the WMQ header context chaining.
|
|
isSupportedFormat(java.lang.String format)
Called by the runtime to determine whether this
MQHeaderDataBinding supports a particular WMQ header format.
|
|
read(java.lang.String format,MQDataInputStream input)
Read the contents of the an incoming WMQ header into its
DataObject representation.
|
|
setNextCCSID(int ccsid)
Called by the runtime before the
write method
and used to "rechain" the WMQ header context chaining.
|
|
setNextEncoding(int encoding)
Called by the runtime before the
write method
and used to "rechain" the WMQ header context chaining.
|
|
setNextFormat(java.lang.String format)
Called by the runtime before the
write method
and used to "rechain" the WMQ header context chaining.
|
|
write(java.lang.String format,MQDataOutputStream output)
Write the header DataObject representation into an outgoing
WMQ message header.
|
Methods inherited from interface commonj.connector.runtime.DataBinding |
---|
getDataObject, setDataObject |
Field Detail
COPYRIGHT
- static final java.lang.String COPYRIGHT
Method Detail
isSupportedFormat
- boolean isSupportedFormat(java.lang.String format)
format
- The format to be queried. read
- void read(java.lang.String format,
- MQDataInputStream input)
- throws java.io.IOException
getDataObject
method is called by the runtime.
An implementation of this method will process the incoming
WMQ header by reading from the supplied input stream. It will
then parse the data into the appropriate DataObject, created
like this: BOFactory bof =
(BOFactory)ServiceManager.INSTANCE.locateService("com/ibm/websphere/bo/BOFactory");
sampleBO = bof.create("http://namespace", "BOName");
format
- In case this MQHeaderDataBinding supports
multiple formats, this parameter determines the
specific header format for this incoming WMQ
header. input
- The input stream wrapping the incoming WMQ
header. java.io.IOException
- Thrown if an error occurs
during reading of the WMQ header. write
- void write(java.lang.String format,
- MQDataOutputStream output)
- throws java.io.IOException
setDataObject
method is called by the runtime.
This method will be the converse of the read
method, and will serialize the contents of the DataObject the
the wire format in the WMQ message header by writing to the
supplied output stream.
format
- In case this MQHeaderDataBinding supports
multiple formats, this parameter determines the
specific header format for this outgoing WMQ
header. output
- The output stream wrapping the outgoing WMQ
message header. java.io.IOException
- Thrown if an error occurs
during writing of the WMQ header. setNextFormat
- void setNextFormat(java.lang.String format)
write
method
and used to "rechain" the WMQ header context chaining.
format
- The format of the next header in the chain. getNextFormat
- java.lang.String getNextFormat( )
read
method and
used to "unchain" the WMQ header context chaining.
setNextCCSID
- void setNextCCSID(int ccsid)
write
method
and used to "rechain" the WMQ header context chaining.
ccsid
- The CCSID of the next header in the chain. getNextCCSID
- int getNextCCSID()
read
method and
used to "unchain" the WMQ header context chaining.
setNextEncoding
- void setNextEncoding(int encoding)
write
method
and used to "rechain" the WMQ header context chaining.
encoding
- The encoding of the next header in the chain. getNextEncoding
- int getNextEncoding()
read
method and
used to "unchain" the WMQ header context chaining.