commonj.connector.runtime
Interface RecordHolderDataBinding

All Superinterfaces:
DataBinding, Serializable

public interface RecordHolderDataBinding
extends DataBinding

A specialization of DataBinding interface for the resource adapter implementation. It allows to get and set the native format of the data as the implementation of cci.Record. It is used in the invocation of the outbound J2C service when the resource adapter supports the execute method with input only and in the inbound invocation. This must be provided for the adapter that supports Interaction.execute() with input only and for adapter that supports inbound communication.

Since:
1.0

Method Summary
 Record getRecord()
          Get the native representation of data as cci Record.
 void setRecord(Record aRecord)
          Set the native data on the binding.
 
Methods inherited from interface commonj.connector.runtime.DataBinding
getDataObject, setDataObject
 

Method Detail

getRecord

Record getRecord()
                 throws DataBindingException
Get the native representation of data as cci Record. For the outbound case, the Record is then passed to the execute method of the Interaction. For the inbound, the record is returned from the listener method (for example onMessage). For the inbound case, if the resource adapter does not support InboundListener interface, the record may be the instance of the InboundNativeDataRecord.

Returns:
Native representation of the data as cci Record. The returned value may be null which indicates that there is no native data. Any error must be reported using DataBindingException.
Throws:
DataBindingException - if an error occured during execution. The cause may contain the original exception.

setRecord

void setRecord(Record aRecord)
               throws DataBindingException
Set the native data on the binding. In the outbound case, the cci Record set is the Record returned by the input only execute. For the inbound case, it is the argument of the listener interface method. For the inbound case, if the resource adapter does not support InboundListener interface, the record will be an instance of the InboundNativeDataRecord.

Parameters:
aRecord - Native representation of the data as cci Record. The argument may be null.
Throws:
DataBindingException - if an error occured during execution. The cause may contain the original exception.
See Also:
InboundNativeDataRecord