Class SwiftInterimTransRept
Repesents and manages SWIFT MT-942 Interim Transaction Report messages.
Implements
Inherited Members
Namespace: Subsembly.Swift
Assembly: Subsembly.Sepa.dll
Syntax
public sealed class SwiftInterimTransRept : Swift9xxBase, IEnumerable, IComparable
Remarks
The primary purpose of the SwiftInterimTransRept class is convenient reading and creating of SWIFT MT-942 messages.
Constructors
SwiftInterimTransRept()
Default constructor.
Declaration
public SwiftInterimTransRept()
Remarks
This should only be used when subsequently reading the statement data from a stream or file.
SwiftInterimTransRept(String, String)
Constructs a new SwiftInterimTransRept from scratch.
Declaration
public SwiftInterimTransRept(string sAccountIdentification, string sAccountCurrency)
Parameters
Type | Name | Description |
---|---|---|
System.String | sAccountIdentification | The account identification for which to create the new interim transaction report. |
System.String | sAccountCurrency | The account currency which will be included in the various amounts of the new interim transaction report. |
Remarks
The newly created SwiftInterimTransRept is completely initialised from the given parameters and thus can immediately be written as a MT-942, albeit without any statement lines in it.
The TransactionReference is preset with the string "STARTDISP". However it can be changed at any time.
Exceptions
Type | Condition |
---|---|
System.ArgumentNullException | Either argument was |
Properties
CreationDate
Declaration
protected override DateTime CreationDate { get; }
Property Value
Type | Description |
---|---|
System.DateTime |
Overrides
CreditFloorLimit
Minimum credit transaction amount reported in this message. (MT-942)
Declaration
public SwiftAmt CreditFloorLimit { get; }
Property Value
Type | Description |
---|---|
SwiftAmt | The CreditFloorLimit property corresponds with the field 34F of a SWIFT MT-942 message. |
Remarks
If the SWIFT MT-942 message includes only a single field 34F, then it contains an absolute value and therefore its content will be available through both floor limit properties, CreditFloorLimit and DebitFloorLimit, although only one field was present. If two fields 34F are present, then they will be stored in their corresponding properties.
This property cannot be set. When creating a new SwiftInterimTransRept, the credit floor limit is implicitly set to zero.
DateTime
The date and time at which the report was created. (MT-942)
Declaration
public DateTime DateTime { get; set; }
Property Value
Type | Description |
---|---|
System.DateTime | The DateTime property corresponds with field 13 or 13D of a SWIFT MT-942 message. |
Remarks
When a MT-942 message is read, then its field 13D will be fully interpreted. The indicated timezone is matched against the local timezone that the system is running in, and the resulting DateTime is adjusted such as to represent the creation time in local time.
On the other hand, a simple field 13 is always interpreted in local time.
When the MT-942 is written this will always generate a field 13D. A field 13 is never generated.
DebitFloorLimit
Minimum debit transaction amount reported in this message. (MT-942)
Declaration
public SwiftAmt DebitFloorLimit { get; }
Property Value
Type | Description |
---|---|
SwiftAmt | The DebitFloorLimit property corresponds with the field 34F of a SWIFT MT-942 message. |
Remarks
If the SWIFT MT-942 message includes only a single field 34F, then it contains an absolute value and therefore its content will be available through both floor limit properties, CreditFloorLimit and DebitFloorLimit, although only one field was present. If two fields 34F are present, then they will be stored in their corresponding properties.
This property cannot be set. When creating a new SwiftInterimTransRept, the debit floor limit is implicitly set to zero.
NumberOfCreditEntries
Total number of credit entries in this interim transaction report. (MT-942)
Declaration
public int NumberOfCreditEntries { get; set; }
Property Value
Type | Description |
---|---|
System.Int32 | This value is zero if a new SwiftInterimTransRept was created from scratch. Otherwise it always reflects the actual number of credit entries in StatementLines. For this reason it is a read only property. Its value can only be changed by adding or removing statement lines. |
NumberOfDebitEntries
Total number of debit entries in this interim transaction report. (MT-942)
Declaration
public int NumberOfDebitEntries { get; set; }
Property Value
Type | Description |
---|---|
System.Int32 | This value is zero if a new SwiftInterimTransRept was created from scratch. Otherwise it always reflects the actual number of debit entries in StatementLines. For this reason it is a read only property. Its value can only be changed by adding or removing statement lines. |
SumOfCreditEntries
Total sum of credit entries in this interim transaction report. (MT-942)
Declaration
public SwiftAmt SumOfCreditEntries { get; set; }
Property Value
Type | Description |
---|---|
SwiftAmt | This amount is a zero amount if a new SwiftInterimTransRept was created from scratch. Otherwise it always reflects the actual sum of all credit entries in StatementLines. For this reason it is a read only property. Its value can only be changed by adding or removing statement lines. |
SumOfDebitEntries
Total sum of debit entries in this interim transaction report. (MT-942)
Declaration
public SwiftAmt SumOfDebitEntries { get; set; }
Property Value
Type | Description |
---|---|
SwiftAmt | This amount is a zero amount if a new SwiftInterimTransRept was created from scratch. Otherwise it always reflects the actual sum of all debit entries in StatementLines. For this reason it is a read only property. Its value can only be changed by adding or removing statement lines. |
Methods
AddStatementLine(SwiftStatementLine)
Adds a Statement Line to this Interim Transaction Report.
Declaration
public override void AddStatementLine(SwiftStatementLine aStatementLine)
Parameters
Type | Name | Description |
---|---|---|
SwiftStatementLine | aStatementLine | Statement Line to be added. |
Overrides
Remarks
Whenever a statement line is added by this method, then the Number and Sum of Debit or Credit Entries of this instance is updated according to the value of the added statement line
Exceptions
Type | Condition |
---|---|
System.ArgumentNullException | The parameter aStatementLine was |
ParseField(SwiftStatementReaderState, SwiftField)
Declaration
protected override void ParseField(SwiftStatementReaderState nState, SwiftField aField)
Parameters
Type | Name | Description |
---|---|---|
SwiftStatementReaderState | nState | |
SwiftField | aField |
Overrides
WriteMT942(SwiftWriter)
Writes this complete SwiftInterimTransRept instance as a SWIFT MT-942 message.
Declaration
public void WriteMT942(SwiftWriter aSwiftWriter)
Parameters
Type | Name | Description |
---|---|---|
SwiftWriter | aSwiftWriter | Destination to write the SWIFT MT-942 message to. |
WriteMT942(Stream)
Writes this complete SwiftInterimTransRept instance as a SWIFT MT-942 message.
Declaration
public void WriteMT942(Stream aStream)
Parameters
Type | Name | Description |
---|---|---|
System.IO.Stream | aStream | Output stream to write the SWIFT MT-942 message to. This stream will not be closed by this method. |