com.cyclonecommerce.cybervan.api
Interface IntegrationDocument

All Known Implementing Classes:
DefaultDocument

public interface IntegrationDocument

Represents the content and information concerning a document


Field Summary
static int MAX_REFERENCES
           
static java.lang.String NA
           
static java.lang.String NA_LIT
           
 
Method Summary
 java.lang.String getControlId()
          getControlId
 java.lang.String getCorrelationId()
          getCorrelationId
 java.lang.String getEbXmlAction()
          Return the ebXmlAction of the document was transfered using ebXml
 java.lang.String getEbXmlService()
          Return the ebXmlService if the document was transfered using ebXml
 java.lang.String getFingerprint()
          getFingerPrint
 InterchangeURL getInterchangeHttpsURL()
          getInterchangeHttpsURL For use by remote clients only
 InterchangeURL getInterchangeURL()
          getInterchangeURL For use by remote clients only
 int getMaxReferences()
          Deprecated.  
 java.lang.String getName()
          getName For use by local clients only
 java.lang.String getOriginalName()
          getOriginalName
 int getOriginalSize()
          getOriginalSize
 java.lang.String getPackagingType()
          Get the packaging type (AKA: BusinessProtocol) to used transfering sending a document.
 java.lang.String getPackagingVersion()
          Get the packaging version (AKA: BusinessProtocol) used when transfering a document.
 java.lang.String getPath()
          getPath For use by local clients only
 java.lang.String getPersistedName()
          getPersistedName
 CompanyId getReceiverId()
          getReciverId
 java.lang.String getReference(int referenceNumber)
          Deprecated. Use getUserData instead.
 java.lang.String getRefToMessageId()
          getRefToMessageId
 SecurityLevel getSecurityLevel()
          getSecurityLevel
 CompanyId getSenderId()
          getSenderId
 int getSequenceId()
          getSequenceId
 java.lang.String getTransport()
          getTransport
 int getTransportSize()
          getTransportSize
 DocumentType getType()
          getType
 java.lang.String getUniqueId()
          getUniqueId
 java.util.Properties getUserData()
          Get the additional user defined data.
 void setContent(java.lang.String path)
          setContent - Sets the raw data of the document.
 void setCorrelationId(java.lang.String id)
          setCorrelationId
 void setEbXmlAction(java.lang.String ebXmlAction)
          Set the ebXmlAction if MCD free trading is enabled.
 void setEbXmlService(java.lang.String ebXmlService)
          Set the ebXmlService if MCD free ebXml trading is enabled.
 void setInterchangeHttpsURL(InterchangeURL url)
          setInterchangeHttpsURL - Sets URL to use when communicating with Interchange.
 void setInterchangeURL(InterchangeURL url)
          setInterchangeURL - Sets URL to use when communicating with Interchange.
 void setPackagingType(java.lang.String packagingType)
          Set the packaging type (AKA: BusinessProtocol) to used when transfering a document.
 void setPackagingVersion(java.lang.String packagingVersion)
          Set the packaging version (AKA: BusinessProtocol) to used when transfering a document.
 void setPath(java.lang.String path)
          setPath
 void setReceiverId(CompanyId id)
          setReceiverId - Sets the ID of the document recipient
 void setReference(int referenceNumber, java.lang.String reference)
          Deprecated. Use setUserData instead.
 void setRefToMessageId(java.lang.String id)
          setRefToMessageId
 void setSenderId(CompanyId id)
          setSenderId - Sets the ID of the document sender
 void setUniqueId(java.lang.String uniqueId)
          setUniqueId - Set the documents Unique Id.
 void setUserData(java.util.Properties userProperties)
          Sets additional user defined data that may be used by the packager when constructing the packaged document.
 

Field Detail

MAX_REFERENCES

public static final int MAX_REFERENCES

NA_LIT

public static final java.lang.String NA_LIT

NA

public static final java.lang.String NA
Method Detail

getControlId

public java.lang.String getControlId()
getControlId
Returns:
Returns the EDI control ID. Returns null if not available

getFingerprint

public java.lang.String getFingerprint()
getFingerPrint
Returns:
Returns the fingerprint of the signed data. Returns null if not available

getName

public java.lang.String getName()
getName For use by local clients only
Returns:
Returns the name of the raw data file

getOriginalName

public java.lang.String getOriginalName()
getOriginalName
Returns:
Returns the original file name. Returns null if not available

getOriginalSize

public int getOriginalSize()
getOriginalSize
Returns:
Returns the size, in bytes, of the original, raw data. Returns null if not available

getPath

public java.lang.String getPath()
getPath For use by local clients only
Returns:
Returns the full path of the raw data file

setPath

public void setPath(java.lang.String path)
setPath
Parameters:
path - the full path of the raw data file

getReceiverId

public CompanyId getReceiverId()
getReciverId
Returns:
Retruns the ID of the document recipient. Returns null if not available

getReference

public java.lang.String getReference(int referenceNumber)
Deprecated. Use getUserData instead.

getReference
Parameters:
referenceNumber - The reference index ( zero based )
Returns:
Returns the specified user defined reference. Returns null if not available

getInterchangeURL

public InterchangeURL getInterchangeURL()
getInterchangeURL For use by remote clients only
Returns:
Returns the HTTP url to use to retreive the raw document content. Returns null if not available

getInterchangeHttpsURL

public InterchangeURL getInterchangeHttpsURL()
getInterchangeHttpsURL For use by remote clients only
Returns:
Returns the HTTPS URL to use to retreive the raw document content. Returns null if not available

getSecurityLevel

public SecurityLevel getSecurityLevel()
getSecurityLevel
Returns:
Returns the level of security used when transporting the document. Returns null if not available

getSenderId

public CompanyId getSenderId()
getSenderId
Returns:
CompanyId ID of the document sender. Returns null if not available

getTransportSize

public int getTransportSize()
getTransportSize
Returns:
Returns the size of the document, in bytes, at the time of tranport ( including compression, security and packaging ). Returns null if not available

getTransport

public java.lang.String getTransport()
getTransport
Returns:
Returns the transport the document was received on. Returns null if not available

getType

public DocumentType getType()
getType
Returns:
Returns the type of the document. Returns null if not available

getUniqueId

public java.lang.String getUniqueId()
getUniqueId
Returns:
Returns a unique document ID. This ID is generated by Interchange Server and is used for tracking purposes

setUniqueId

public void setUniqueId(java.lang.String uniqueId)
setUniqueId - Set the documents Unique Id. This ID is used by the Interchange Server for tracking purposes. If the UniqueId is not set by the api client, then Interchange will assigne an id. Make sure when calling this method that the id is globally unique.

getCorrelationId

public java.lang.String getCorrelationId()
getCorrelationId
Returns:
Returns the document Correlation Id. This id can be generated by Interchange, or generated by applications integrating with Interchange. The id is used to tie together multiple documents into a conversation. Multiple documents can have the same Correlation Id.

setCorrelationId

public void setCorrelationId(java.lang.String id)
setCorrelationId
Parameters:
id - The document Correlation Id. This id can be generated by Interchange, or generated by applications integrating with Interchange. The id is used to tie together multiple documents into a conversation. Multiple documents can have the same Correlation Id.

getRefToMessageId

public java.lang.String getRefToMessageId()
getRefToMessageId
Returns:
Returns the document RefToMessageId. The MessageId in which this (current) document refers to (or is a response to).

setRefToMessageId

public void setRefToMessageId(java.lang.String id)
setRefToMessageId
Parameters:
id - document RefToMessageId. This id can be generated by

getSequenceId

public int getSequenceId()
getSequenceId
Returns:
Returns a unique document sequence ID. This ID is generated by Inbound Agent and is only set when sequencing is turned on by partner's inbound configuration.

getPersistedName

public java.lang.String getPersistedName()
getPersistedName
Returns:
Returns the name of the document as persisted on disk.

setInterchangeURL

public void setInterchangeURL(InterchangeURL url)
setInterchangeURL - Sets URL to use when communicating with Interchange. Cyclone Internal use only
Parameters:
url -  

setInterchangeHttpsURL

public void setInterchangeHttpsURL(InterchangeURL url)
setInterchangeHttpsURL - Sets URL to use when communicating with Interchange. Cyclone Internal use only
Parameters:
url -  

setContent

public void setContent(java.lang.String path)
setContent - Sets the raw data of the document. For use by local clients only
Parameters:
path - The full path of the file containing the raw data

setReceiverId

public void setReceiverId(CompanyId id)
setReceiverId - Sets the ID of the document recipient
Parameters:
id - The company ID

setReference

public void setReference(int referenceNumber,
                         java.lang.String reference)
Deprecated. Use setUserData instead.

setReference - Sets the specified user defined reference
Parameters:
referenceNumber - The reference index
reference - The user specifed reference

setSenderId

public void setSenderId(CompanyId id)
setSenderId - Sets the ID of the document sender
Parameters:
id - The company ID

getMaxReferences

public int getMaxReferences()
Deprecated.  

getMaxReferences - Gets the maximum number of references
Returns:
int

getEbXmlService

public java.lang.String getEbXmlService()
Return the ebXmlService if the document was transfered using ebXml

setEbXmlService

public void setEbXmlService(java.lang.String ebXmlService)
Set the ebXmlService if MCD free ebXml trading is enabled. The ebXmlService must be set if trading ebXml without using a MCD.

getEbXmlAction

public java.lang.String getEbXmlAction()
Return the ebXmlAction of the document was transfered using ebXml

setEbXmlAction

public void setEbXmlAction(java.lang.String ebXmlAction)
Set the ebXmlAction if MCD free trading is enabled. The ebXmlAction must be set if trading ebXml without using a MCD.

getPackagingType

public java.lang.String getPackagingType()
Get the packaging type (AKA: BusinessProtocol) to used transfering sending a document.
Returns:
String

setPackagingType

public void setPackagingType(java.lang.String packagingType)
Set the packaging type (AKA: BusinessProtocol) to used when transfering a document. The packaging type only needs to be set if trading ebXml without using a MCD.
Parameters:
packagingType - The packaging type

getPackagingVersion

public java.lang.String getPackagingVersion()
Get the packaging version (AKA: BusinessProtocol) used when transfering a document.
Returns:
String

setPackagingVersion

public void setPackagingVersion(java.lang.String packagingVersion)
Set the packaging version (AKA: BusinessProtocol) to used when transfering a document. The packaging version only needs to be set if trading ebXml without using a MCD.
Parameters:
packagingVersion - The packaging version

setUserData

public void setUserData(java.util.Properties userProperties)
Sets additional user defined data that may be used by the packager when constructing the packaged document. Currently the properties are only utilized when packaging ebXML documents. setUserData can be called for outbound documents. The properties will be used to populate the ebXML #wildcard element.
Parameters:
userProperties - Initialized with user defined data.

getUserData

public java.util.Properties getUserData()
Get the additional user defined data. Currently the properties are only supported for ebXML documents. getUserData can be called for Inbound Documents. The properties will be read from the inbound ebXML document's #wildcard element.
Returns:
Additional user data transfered within the headers of a inbound document.