Class DtazvParser
Parser for DTAZV files.
public class DtazvParser : DtazvBase
- Inheritance
-
DtazvParser
- Inherited Members
Constructors
DtazvParser(byte[])
public DtazvParser(byte[] vbDtausData)
Parameters
vbDtausDatabyte[]Provides the raw binary DTAUS data to be processed by this DtazvParser instance. This parameter must not be
null, but the buffer may be empty.
Exceptions
- ArgumentNullException
The parameter
vbDtausDatawasnull.- ArgumentException
The length of the provided data buffer was not a muplitiple of the block size of 128 bytes.
Properties
BankCode
The bank code from ReadRecordQ().
public string BankCode { get; }
Property Value
BuildDate
The build date from field Q6 from the most recent record Q.
public DateTime BuildDate { get; }
Property Value
- DateTime
If no record Q was read so far, then this property has the value DateTime.MinValue.
CustomerNumber
The customer number from ReadRecordQ().
public string CustomerNumber { get; }
Property Value
DailySeqNo
The daily sequence number from ReadRecordQ().
public int DailySeqNo { get; }
Property Value
Initiator
The initiator name and address from ReadRecordQ().
public DtazvNameAndAddress Initiator { get; }
Property Value
RecordSize
Indicates the logical record size of the next record to be read.
public int RecordSize { get; }
Property Value
- int
If the input is exhausted, then this will be zero.
RecordType
Indicates the type of the next record to be read.
public char RecordType { get; }
Property Value
- char
This is a NUL character if the input is exhausted.
ScheduleDate
The schedule date from field Q8 from the most recent record Q.
public DateTime ScheduleDate { get; }
Property Value
- DateTime
If no schedule date was set in the DTAZV file, or no record Q was read so far, then this property has the value DateTime.MinValue.
Methods
ReadDTAZV(byte[])
Reads a complete DTAZV file from a data buffer.
public static SepaDocument ReadDTAZV(byte[] vbDtausData)
Parameters
vbDtausDatabyte[]Binary buffer that contains the DTAZV data to be parsed.
Returns
- SepaDocument
Returns a SepaDocument according to the German AXZ pain.001.001.09 format.
Remarks
All T records that are read from the DTAZV data buffer are converted into individual SepaCreditTransferPaymentInformation instances, with a single SepaCreditTransferTransactionInformation child element.
The default ServiceLevelCode of the returned transactions is NURG. If the DTAZV field T22 contains "10", then the payment type will be URGP.
Exceptions
- ArgumentNullException
The parameter
vbDtausDatawasnull.
ReadDTAZV(string)
Reads a complete DTAZV file.
public static SepaDocument ReadDTAZV(string sFileName)
Parameters
sFileNamestringFile name of DTAZV file to be read. This file may contain multiple logical files.
Returns
Remarks
All T records that are read from the DTAZV data buffer are converted into individual SepaCreditTransferPaymentInformation instances, with a single SepaCreditTransferTransactionInformation child element.
Exceptions
- ArgumentNullException
The parameter
sFileNamewasnull.- ArgumentException
The parameter
sFileNamewas an empty string.
ReadRecordQ()
public bool ReadRecordQ()
Returns
- bool
If the input data is already exhausted when this method is called, then
falseis returned. If a record Q was read, thentrueis returned.
Exceptions
- DtazvException
The input data doesn't start with a DTAZV record Q header.
ReadRecordT()
Reads a DTAZV record T from the input data.
public SepaCreditTransferPaymentInformation ReadRecordT()
Returns
- SepaCreditTransferPaymentInformation
The data from the T record is collected in a new SepaCreditTransferPaymentInformation instance which is returned by this method. If an immediate end of data was encountered, then
nullis returned.
Remarks
The ServiceLevelCode of the returned transactions is always NURG. If the DTAZV field T22 contains "10", then the payment type will be URGP.
Exceptions
- DtazvException
The input data doesn't start with a DTAZV record T header.
ReadRecordZ()
Reads a complete Z record and validates total amount/total count.
public bool ReadRecordZ()
Returns
- bool
If the input data is already exhausted when this method is called, then
falseis returned. If a record Z was read, thentrueis returned.
Exceptions
- DtazvException
The input data doesn't start with a DTAZV record Z header. The calculated total amount (over all T records) differs from the total amount from the Z record (checksum error). The number of read T records differs from the total count field in this Z record (checksum error).
Reset()
Resets the properties and the check sums, but not the input offset.
public void Reset()