Class FinStatus
Represents a single FinTS status record (Rueckmeldung) as it is sent from the server to the client.
public class FinStatus : ICloneable
- Inheritance
-
FinStatus
- Implements
- Inherited Members
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()
public FinStatus()
FinStatus(FinStatus)
public FinStatus(FinStatus aStatus)
Parameters
aStatus
FinStatus
Properties
Code
The FinTS status code (Rueckmeldecode) of this status record.
public int Code { get; set; }
Property Value
- int
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
- 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.
public string CodeAsString { get; }
Property Value
DEG
Optional DEG position of the data element that this status record refers to.
public int DEG { get; }
Property Value
- int
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(int) SetRef(int, int)
GD
Optional GD position of the data element that this status record refers to.
public int GD { get; }
Property Value
- int
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(int) SetRef(int, int)
Parameters
The parameters of this status record.
public string[] Parameters { get; set; }
Property Value
- 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.
public string Ref { get; set; }
Property Value
- 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
- 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.
public string Text { get; set; }
Property Value
- string
Each status record has a text message of up to 80 characters length.
Methods
Clone()
public virtual object Clone()
Returns
GetStatusDEG(FinSegment, int)
Extract a complete status record from a data element group.
public static FinStatus GetStatusDEG(FinSegment aSegment, int nDEG)
Parameters
aSegment
FinSegmentSegment that contains the status data element group. Currently this can be either a HIRMG, HIRMS or HIPRO segment.
nDEG
intThe DEG position of the status data element group to be read.
Returns
SetParameters(params string[])
public void SetParameters(params string[] vsParameters)
Parameters
vsParameters
string[]
SetRef(int)
Set a DE reference for this status record.
public FinStatus SetRef(int nDE)
Parameters
nDE
intThe DE position in the range from 1 through 999.
Returns
Remarks
This sets a DE reference for this status record, implicitly clearing any previous DEG,GD reference. DEG GD Ref SetRef(int, int)
Exceptions
- ArgumentOutOfRangeException
Trying to set a value outside the allowed range will cause an ArgumentOutOfRangeException to be thrown.
SetRef(int, int)
Set a DEG,GD reference for this status record.
public FinStatus SetRef(int nDEG, int nGD)
Parameters
nDEG
intThe DEG position in the range from 1 through 999.
nGD
intThe GD position in the range from 1 through 999.
Returns
Remarks
This sets a DEG,GD reference for this status record, implicitly clearing any previous DEG,GD reference. DEG GD Ref SetRef(int)
Exceptions
- 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.
public override string ToString()
Returns
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.
public string ToString(FinStatusParts nParts)
Parameters
nParts
FinStatusPartsSelects the parts of the status that should be included in the produced string.
Returns
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.