Class EbicsTransaction
Manages a client side EBICS transaction.
Inherited Members
Namespace: Subsembly.EBICS
Assembly: Subsembly.EBICS.Core.dll
Syntax
public class EbicsTransaction : EbicsTrace
Remarks
An EbicsTransaction instance creates EBICS requests and processes EBICS reponses for a single EBICS transaction that sends an EbicsOrder on behalf of an EbicsContact. It implements a state machine that builds and processes all the EBICS XML messages that are sent and received during the EBICS transaction.
After creating a new EbicsTransaction instance, its method BuildRequest() must be called in order to build the next EBICS request message to be sent to the EBICS host. The XML response received from the EBICS host must then be passed to the ProcessResponse(XmlDocument) method. This must be repeated until the transaction is completed, or failed unrecoverably.
Constructors
EbicsTransaction(EbicsContact, EbicsOrder, IEbicsSecurityOperations)
Declaration
public EbicsTransaction(EbicsContact aContact, EbicsOrder aOrder, IEbicsSecurityOperations aSecurityMedium)
Parameters
Type | Name | Description |
---|---|---|
EbicsContact | aContact | The EBICS contact (user) that will conduct this transaction. This must not be
|
EbicsOrder | aOrder | The order to be sent in a EBICS transaction. This must not be |
IEbicsSecurityOperations | aSecurityMedium | Authenticated security medium of the user that will be used to create the authentication signature and to decrypt received data. |
Exceptions
Type | Condition |
---|---|
System.ArgumentNullException | One of the required parameters was |
Fields
MAXPRODUCTINSTITUTEIDLENGTH
Maximum length of ProductInstituteID name property (=64).
Declaration
public const int MAXPRODUCTINSTITUTEIDLENGTH = 64
Field Value
Type | Description |
---|---|
System.Int32 |
MAXPRODUCTLENGTH
Maximum length of Product name property (=64).
Declaration
public const int MAXPRODUCTLENGTH = 64
Field Value
Type | Description |
---|---|
System.Int32 |
Properties
Product
The product information to be sent in the request header.
Declaration
public string Product { get; set; }
Property Value
Type | Description |
---|---|
System.String | The product description may contain up to MAXPRODUCTLENGTH
characters. If it is |
Remarks
The default value for this property is "Subsembly EBICS" and the full version number of the Subsembly EBICS API.
ProductInstituteID
The product institute ID information to be sent in the request header.
Declaration
public string ProductInstituteID { get; set; }
Property Value
Type | Description |
---|---|
System.String | The product institute ID may contain up to MAXPRODUCTINSTITUTEIDLENGTH
characters. If it is |
Remarks
The default value for this property is "Subsembly GmbH".
ProductLanguage
The product language information to be sent in the request header.
Declaration
public string ProductLanguage { get; set; }
Property Value
Type | Description |
---|---|
System.String | If a Product information is specified, then the ProductLanguage must be specified, too. |
Remarks
The default value of this property is "de".
TimestampBankParameter
Declaration
public DateTime TimestampBankParameter { get; }
Property Value
Type | Description |
---|---|
System.DateTime |
TransactionID
Declaration
public string TransactionID { get; }
Property Value
Type | Description |
---|---|
System.String |
TransactionState
Declaration
public EbicsTransactionState TransactionState { get; }
Property Value
Type | Description |
---|---|
EbicsTransactionState |
Methods
BuildRequest()
Builds the next EBICS request XML document to be sent for this transaction.
Declaration
public XmlDocument BuildRequest()
Returns
Type | Description |
---|---|
System.Xml.XmlDocument | Returns a newly created XmlDocument that represents the complete EBICS request to
send. If this transaction was already completed, then |
Execute(IEbicsTransport)
Executes this transaction online.
Declaration
public EbicsErrorClass Execute(IEbicsTransport aTransport)
Parameters
Type | Name | Description |
---|---|---|
IEbicsTransport | aTransport |
Returns
Type | Description |
---|---|
EbicsErrorClass | Returns the worse error class from the technical and business return codes (if any). If the transaction failed completely without ever receiving a return code, then an exception is thrown. |
ProcessResponse(XmlDocument)
Declaration
public bool ProcessResponse(XmlDocument xmlDocument)
Parameters
Type | Name | Description |
---|---|---|
System.Xml.XmlDocument | xmlDocument |
Returns
Type | Description |
---|---|
System.Boolean | If this was the final response of a transaction, then |
Exceptions
Type | Condition |
---|---|
EbicsException | The structure or content of the response message was no valid EBICS XML. |