Class OutboundProcessingContext
java.lang.Object
com.onenetwork.platform.integ.msg.OutboundProcessingContext
- Direct Known Subclasses:
ModelOutboundProcessingContext
,NetChangeOutboundProcessingContext
,SysIdOutboundProcessingContext
public abstract class OutboundProcessingContext
extends java.lang.Object
Base class for the context provided to outbound processors.
-
Constructor Summary
Constructors Constructor Description OutboundProcessingContext(java.lang.String outboundInterfaceName, java.lang.String OutboundInterfaceVersion, java.io.OutputStream outputStream, PlatformUserContext platformUserContext)
-
Method Summary
Modifier and Type Method Description void
addMessageDetail(java.lang.String strRecordIdentifier, java.lang.String strPrimaryRefTransNumber, java.lang.String strModelType, java.lang.String strRawData)
Convenience method to generateMessageDetail
for a record.java.util.List<MessageDetail>
getMessageDetails()
java.lang.String
getOutboundInterfaceName()
java.lang.String
getOutboundInterfaceVersion()
java.io.OutputStream
getOutputStream()
PlatformUserContext
getPlatformUserContext()
OutboundInterfaceWriteRequest
getRequest()
Sets the outboundInterfaceWriteRequest which initiated outbound generation.void
setRequest(OutboundInterfaceWriteRequest request)
-
Constructor Details
-
OutboundProcessingContext
public OutboundProcessingContext(java.lang.String outboundInterfaceName, java.lang.String OutboundInterfaceVersion, java.io.OutputStream outputStream, PlatformUserContext platformUserContext)- Parameters:
outboundInterfaceName
- outbound interface nameoutboundInterfaceVersion
- outbound interface version (can use null to indicate most recent version)outputStream
-OutputStream
into which the outbound message should be writtenplatformUserContext
- - VC level user or an user under a VC
-
-
Method Details
-
getOutboundInterfaceName
public java.lang.String getOutboundInterfaceName()- Returns:
- name of the interface being invoked
-
getOutboundInterfaceVersion
public java.lang.String getOutboundInterfaceVersion()- Returns:
- version of the interface being invoked
-
getOutputStream
public java.io.OutputStream getOutputStream()- Returns:
- the outputStream to which the outbound file should be written by the generator
-
getPlatformUserContext
- Returns:
- context of the user invoking the outbound integration
-
getRequest
Sets the outboundInterfaceWriteRequest which initiated outbound generation. -
setRequest
-
addMessageDetail
public void addMessageDetail(java.lang.String strRecordIdentifier, java.lang.String strPrimaryRefTransNumber, java.lang.String strModelType, java.lang.String strRawData)Convenience method to generateMessageDetail
for a record. Custom outbound generator should use this method instead of usingMessageDetailService
since it requiresMessage
object for creatingMessageDetail
.- Parameters:
strRecordIdentifier
- record identifier, for example row numberstrPrimaryRefTransNumber
- reference number for the business transaction this message detail affectedstrModelType
- model type of the business transaction this message detail affectedstrRawData
- raw data of the message detail (for example CSV row content)
-
getMessageDetails
- Returns:
- List of MessageDetail which are added by Custom outbound generator
-