Class FinStatus
Represents a single FinTS status record (Rueckmeldung) as it is sent from the server to the client.
Inheritance
Implements
Inherited Members
Namespace: Subsembly.FinTS
Assembly: Subsembly.FinTS.Core.dll
Syntax
public class FinStatus : ICloneable
Remarks
FinTS status records are sent from the server to the client in HIRMS, HIRMG and HIPRO segments. A single HIRMS or HIRMG segment can contain up to 99 status records. The class FinStatusSegment is used to encapsulate a complete HIRMS or HIRMG segment.
Constructors
FinStatus()
Declaration
public FinStatus()
FinStatus(FinStatus)
Declaration
public FinStatus(FinStatus aStatus)
Parameters
Type | Name | Description |
---|---|---|
FinStatus | aStatus |
Properties
Code
The FinTS status code (Rueckmeldecode) of this status record.
Declaration
public int Code { get; set; }
Property Value
Type | Description |
---|---|
System.Int32 | The status code must be in the range from 0 through 9999. |
Remarks
Inside a segment the status code is formatted as a string of four digits with leading zeroes.
The status code classifies the status as either successful (value 0 through 999), successful with info (value 1000 through 1999), successful with warning (value 3000 through 3999), or failure (value 9000 through 9999). Other ranges are not defined in FinTS, but are allowed here.
Exceptions
Type | Condition |
---|---|
System.ArgumentOutOfRangeException | Trying to set a value outside the allowed range will cause an ArgumentOutOfRangeException to be thrown. |
CodeAsString
The FinTS status code (Rueckmeldecode) of this status record as 4-digit-string.
Declaration
public string CodeAsString { get; }
Property Value
Type | Description |
---|---|
System.String |
DEG
Optional DEG position of the data element that this status record refers to.
Declaration
public int DEG { get; }
Property Value
Type | Description |
---|---|
System.Int32 | A valid DEG position is in the range from 1 through 999. The segment header DEG is the first DEG and has position one. The value zero is used to indicate that no DEG position was specified. |
Remarks
Inside the status segment the DEG position is part of the reference data element and does not constitute a data element by itself. Ref SetRef(Int32) SetRef(Int32, Int32)
GD
Optional GD position of the data element that this status record refers to.
Declaration
public int GD { get; }
Property Value
Type | Description |
---|---|
System.Int32 | A valid GD position is in the range from 1 through 999. The first GD of a DEG has position one. The value zero is used to indicate that no GD position was specified. If a valid (nonzero) GD position is given, then a valid (nonzero) DEG position is given, too. |
Remarks
Inside the status segment the GD position is part of the reference data element and does not constitute a data element by itself. DEG Ref SetRef(Int32) SetRef(Int32, Int32)
Parameters
The parameters of this status record.
Declaration
public string[] Parameters { get; set; }
Property Value
Type | Description |
---|---|
System.String[] | A status record may have up to 10 parameters with up to 35 characters each. |
Ref
Access to reference data element in its string format.
Declaration
public string Ref { get; set; }
Property Value
Type | Description |
---|---|
System.String | If this status record does not contain a reference data element, then this Ref property is null. Otherwise it holds a string in the format DE or DEG,GD. |
Exceptions
Type | Condition |
---|---|
System.ArgumentOutOfRangeException | Trying to set a value outside the allowed range will cause an ArgumentOutOfRangeException to be thrown. |
Text
The text message of this status record.
Declaration
public string Text { get; set; }
Property Value
Type | Description |
---|---|
System.String | Each status record has a text message of up to 80 characters length. |
Methods
Clone()
Declaration
public virtual object Clone()
Returns
Type | Description |
---|---|
System.Object |
GetStatusDEG(FinSegment, Int32)
Extract a complete status record from a data element group.
Declaration
public static FinStatus GetStatusDEG(FinSegment aSegment, int nDEG)
Parameters
Type | Name | Description |
---|---|---|
FinSegment | aSegment | Segment that contains the status data element group. Currently this can be either a HIRMG, HIRMS or HIPRO segment. |
System.Int32 | nDEG | The DEG position of the status data element group to be read. |
Returns
Type | Description |
---|---|
FinStatus | The complete status data element group inside a new instance of the FinStatus class. |
SetParameters(String[])
Declaration
public void SetParameters(params string[] vsParameters)
Parameters
Type | Name | Description |
---|---|---|
System.String[] | vsParameters |
SetRef(Int32)
Set a DE reference for this status record.
Declaration
public FinStatus SetRef(int nDE)
Parameters
Type | Name | Description |
---|---|---|
System.Int32 | nDE | The DE position in the range from 1 through 999. |
Returns
Type | Description |
---|---|
FinStatus |
Remarks
This sets a DE reference for this status record, implicitly clearing any previous DEG,GD reference. DEG GD Ref SetRef(Int32, Int32)
Exceptions
Type | Condition |
---|---|
System.ArgumentOutOfRangeException | Trying to set a value outside the allowed range will cause an ArgumentOutOfRangeException to be thrown. |
SetRef(Int32, Int32)
Set a DEG,GD reference for this status record.
Declaration
public FinStatus SetRef(int nDEG, int nGD)
Parameters
Type | Name | Description |
---|---|---|
System.Int32 | nDEG | The DEG position in the range from 1 through 999. |
System.Int32 | nGD | The GD position in the range from 1 through 999. |
Returns
Type | Description |
---|---|
FinStatus |
Remarks
This sets a DEG,GD reference for this status record, implicitly clearing any previous DEG,GD reference. DEG GD Ref SetRef(Int32)
Exceptions
Type | Condition |
---|---|
System.ArgumentOutOfRangeException | Trying to set a value outside the allowed range will cause an ArgumentOutOfRangeException to be thrown. |
ToString()
Creates an human readable string from this status record.
Declaration
public override string ToString()
Returns
Type | Description |
---|---|
System.String |
Overrides
Remarks
The returned string looks like this:
"0000 Status Text (0,0; Parameter 1; Parameter 2)"
First is the four digit status code, followed by a blank and the complete status text. If a reference or parameter exists, then they are appended within brackets, separated by a semicolon.
ToString(FinStatusParts)
Creates an human readable string from this status record.
Declaration
public string ToString(FinStatusParts nParts)
Parameters
Type | Name | Description |
---|---|---|
FinStatusParts | nParts | Selects the parts of the status that should be included in the produced string. |
Returns
Type | Description |
---|---|
System.String |
Remarks
The returned string looks like this:
"0000 Status Text (0,0; Parameter 1; Parameter 2)"
First is the four digit status code, followed by a blank and the complete status text. If a reference or parameter exists, then they are appended within brackets, separated by a semicolon.