EDI Integrator V9 - Online Help
Available for:
EDI Integrator V9
Questions / Feedback?

RNIFReceiver Component

Properties   Methods   Events   Configuration Settings   Errors  

The RNIFReceiver component implements a RosettaNet server.

Syntax

nsoftware.InEDI.Rnifreceiver

Remarks

The RNIFReceiver implements server-side receiving of RosettaNet messages, as specified by the RosettaNet community. It can be used to decrypt and verify incoming messages and to generate synchronous receipts and replies if needed. The component is designed to be easily incorporated into an HTTP server. RosettaNet is used in a variety of industries including Semiconductor Manufacturing, Electronic Components, Telecommunications, Logistics, the Chemical Industry (through CIDX), and more.

BASIC OPERATION

When a RosettaNet request comes in, you should first call the ReadRequest method to read in the request. Once this is done, you must parse the headers and the request. You first parse the headers of the HTTP request using the ParseHeaders method. You may then set the appropriate certificates by setting the Certificate to your private key certificate and SignerCert to your trading partner's (signing) certificate.

The next step is to parse the RosettaNet message using ParseRequest. This method decrypts the message if needed. The component then parses all parts of the message. The preamble, delivery, and service headers are all parsed into the PreambleHeaderXML, DeliveryHeaderXML, and the ServiceHeaderXML, respectively. It also parses the actual body of the RosettaNet message, or the PIP, into the ServiceContent. Any attachments that may be in the message are parsed into the attachment array, and may be accessed via the Attachments property.

The component can also be used to handle synchronous responses. In order to complete this task, the receiver must first reset all header properties to values appropriate for a response. This may include changing values such as the MessageSenderId, MessageReceiverId, ActionCode, etc. The ServiceContent should then be set to a response indicating the state of the transaction. A typical response is a simple receipt acknowledgement, which has all qualities of a valid RosettaNet action, but is simply a receipt. Once these properties have been set, the message is ready to be sent using the AckRequest method.

NOTE: the RNIFReceiver Component can only handle sending synchronous responses. If an asynchronous response is desired, or required by a particular Partner Interface Process (PIP), you should use the RNIFSender component.

The following example illustrates how to use the component within a web page.

EXAMPLE


RNIFReceiver.ReadRequest();
RNIFReceiver.Certificate = new Certificate(CertStoreTypes.cstPFXFile,          // Store type
                                           "\my_server_directory\encrypt.pfx", // File name
                                           "my password",                      // Password
                                           "CN=Encrypt");                      // Subject

RNIFReceiver.SignerCert = new Certificate("\my_server_directory\partnercert.cer");
RNIFReceiver.ParseHeaders();
RNIFReceiver.ParseRequest();

The server can then get the data from the preamble header, delivery header, service header, and the PIP content from their properties: PreambleHeaderXML, DeliveryHeaderXML, ServiceHeaderXML<;, and the ServiceContent, respectively. The message may then be easily processed, as all details of the transaction will be populated into their respective properties.

NOTE: Any attachments are saved by the name in the corresponding Attachments entry, and in the directory specified by the receiver. The directory is specified using the AttachmentOutputPath config property, and must be specified before you read and process the request. For example:


RNIFReceiver.Config("AttachmentOutputPath='\my_server_directory\Attachments'")

NOTE: In the above example, a receipt acknowledgement was not sent.

Additional functionality allows the user to examine details of the client's request, to permit certain types of errors, or to customize the RosettaNet response message. See the property and method list for details.

Property List


The following is the full list of the properties of the component with short descriptions. Click on the links for further details.

ActionCodeThe code for this action.
ActionMessageWhether or not this message is an action message.
ActionMessageStandardNameThe name of the standard used to create this action.
ActionMessageStandardVersionThe version of the standard used to create this action.
AttachmentsA collection of files attached to the current RNIF message.
BusinessActivityThis property denotes the type of business activity.
CertificateThe encryption certificate.
DeliveryHeaderXMLThe complete XML data from the Delivery Header.
EncryptionAlgorithmThe algorithm used to encrypt the EDI data.
EncryptionTypeThe encryption type for RNIF 2.0.
FromRoleThe business role of the entity that originated this message.
FromServiceThe service that originated this message.
GlobalUsageCodeA universal code describing basic usage for this message.
MessageDateTimeThe time at which this message was sent.
MessageReceiverIdIdentity of the entity receiving this message.
MessageReceiverLocationLocation of the entity receiving this message.
MessageSenderIdIdentity of the entity that sent this message.
MessageSenderLocationLocation of the entity that sent this message.
MessageTrackingIdUnique value that identifies this message.
OriginalActionCodeThe action code of the original message.
OriginalMessageStandardNameThe name of the standard used to create the original message.
OriginalMessageStandardVersionThe version of the standard used to create the original message.
OriginalMessageTrackingIdTracking identifier for the original message.
PartnerIdIdentity of the partner.
PartnerKnownWhether or not the partner is known.
PartnerLocationLocation of the partner.
PartnerPIPBindingIdThe partner-defined PIP payload binding ID.
PartnerURLA URL to which replies must be sent if the partner is unknown.
PIPCodeRosettaNet PIP code of this message.
PIPInstanceIdThe ID of this PIP instance.
PIPVersionRosettaNet PIP version of this message.
PreambleHeaderXMLThe complete XML data from the Preamble Header.
QOSSpecificationsSpecifies quality of service constraints for this message.
RecipientCertThe encryption certificate of the recipient.
ReplyMessageWhether or not this message is a reply to another message.
RequestThe HTTP request to be processed.
RequestHeadersThe HTTP headers in the RNIF request.
RequestHeadersStringThe HTTP headers in the RNIF request.
ResponseTypeRequested response type. Available only in RNIF 2.0.
RNIFVersionThe RNIF Standard Version used to generate this message.
SecureTransportRequiredIndicates that security is required when forwarding this message.
ServiceContentThe PIP message data.
ServiceHeaderXMLThe complete XML data from the Service Header.
SignalCodeThe code for this signal.
SignalMessageWhether or not this message is a signal.
SignalVersionThe version of this signal.
SignerCertYour trading partner's signing certificate.
StandardNameThe name of the standard used to create this message.
StandardVersionThe version of the standard used to create this message.
ToRoleThe role of the entity receiving this message.
ToServiceThe service for which this message is bound.

Method List


The following is the full list of the methods of the component with short descriptions. Click on the links for further details.

ConfigSets or retrieves a configuration setting .
ParseHeadersProcesses the headers, and populates the appropriate properties.
ParseRequestParses the MIME message and determines the Message .
ReadRequestReads the RNIF request from the given HTTP servlet request.
RequestHeaderGets the specified header from the HTTP request.
ResetThis property is used to reset all attributes of the Rnifreceiver instance.
SendResponseOptional. Acknowledges the incoming request.
SetRequestStreamSets the stream from which the component will read the RNIF request.

Event List


The following is the full list of the events fired by the component with short descriptions. Click on the links for further details.

Configuration Settings


The following is a list of configuration settings for the component with short descriptions. Click on the links for further details.

AttachmentOutputPathAllows the specification of an output path to which attachments will be written to.
ExpectedVersionThe RNIF document version that the RNIFReceiver is expecting to receive.
HTTPStatusCodeThe HTTP status code to send in the response.
FromPartnerClassificationCodeCode identifying the sending partner's function in the supply chain.
GlobalProcessCodeBusiness process identifier e.g. 'Manage Product Subscriptions'. This code is the name of a PIP specification document.
MessageDigestThe base-64 encoded hash of the received data.
RequireEncryptionWhether encryption is required when processing received messages.
RequireSignatureWhether a signature is required when processing received messages.
ToPartnerClassificationCodeCode identifying the receiving partner's function in the supply chain.
TransactionCodeService transaction dialog. The code is the name of the business activity and the transaction dialog in the PIP specification document.
TransactionIdA unique alpha-numeric identifier that represents a specific instance of an business process, business transaction, business action or business signal. The instance identifier must be unique for a particular instance of a business process, business transaction, business action and business signal.
TransferredHeadersThe HTTP headers of the incoming request.
TransferredDataThe full body of the incoming request.
SignatureAlgorithmSignature algorithm to be used in outgoing messages.
CodePageThe system code page used for Unicode to Multibyte translations.

 
 
Copyright (c) 2018 /n software inc. - All rights reserved.
Build 9.0.6635.0