Class FinPersist
Abstract base class that provides common methods for all persistent objects in the
FinTS Subsembly.
Assembly: Subsembly.FinTS.Core.dll
Syntax
public abstract class FinPersist
Constructors
FinPersist()
Declaration
FinPersist(string)
Declaration
protected FinPersist(string sXmlRootTag)
Parameters
Type |
Name |
Description |
string |
sXmlRootTag |
The default root tag that is used when persisting this object in XML format.
|
Properties
RootTag
The XML root tag of this object that was given to the contructor.
Declaration
public string RootTag { get; }
Property Value
Methods
Load(string)
Loads object state from given file.
Declaration
public void Load(string sFilename)
Parameters
Type |
Name |
Description |
string |
sFilename |
Complete filename including path. Must not be null or an empty string.
|
Exceptions
LoadXml(string)
Loads object state from given XML string.
Declaration
public void LoadXml(string sXml)
Parameters
Type |
Name |
Description |
string |
sXml |
XML string that contains the object state to be loaded.
|
Exceptions
Read(Stream)
Reads object state from the given stream.
Declaration
public void Read(Stream aStream)
Parameters
Type |
Name |
Description |
Stream |
aStream |
Stream to read object state from. Must not be null and must be
readable.
|
Exceptions
ReadXml(XmlReader)
Callback that is ultimately invoked in order to read the XML representation of
this object.
Declaration
public abstract void ReadXml(XmlReader aXmlReader)
Parameters
ReadXmlDocument(XmlReader)
Declaration
public string ReadXmlDocument(XmlReader aXmlReader)
Parameters
Returns
ReadXmlElement(XmlReader, string)
Declaration
protected string ReadXmlElement(XmlReader aXmlReader, string sTag)
Parameters
Returns
ReadXmlElementAcct(XmlReader, string)
Declaration
protected FinAcct ReadXmlElementAcct(XmlReader aXmlReader, string sTag)
Parameters
Returns
ReadXmlElementAmt(XmlReader, string)
Declaration
protected SwiftAmt ReadXmlElementAmt(XmlReader aXmlReader, string sTag)
Parameters
Returns
ReadXmlElementBool(XmlReader, string)
Declaration
protected bool ReadXmlElementBool(XmlReader aXmlReader, string sTag)
Parameters
Returns
ReadXmlElementDate(XmlReader, string)
Declaration
protected SwiftDate ReadXmlElementDate(XmlReader aXmlReader, string sTag)
Parameters
Returns
ReadXmlElementInt(XmlReader, string)
Reads the element and tries to parse it as an integer value. If the element
does not exist, then zero is returned.
Declaration
protected int ReadXmlElementInt(XmlReader aXmlReader, string sTag)
Parameters
Returns
ReadXmlElementSegment(XmlReader, string)
Declaration
protected FinSegment ReadXmlElementSegment(XmlReader aXmlReader, string sTag)
Parameters
Returns
ReadXmlElementTime(XmlReader, string)
Declaration
protected SwiftTime ReadXmlElementTime(XmlReader aXmlReader, string sTag)
Parameters
Returns
SaveAs(string)
Saves object state to the given file.
Declaration
public void SaveAs(string sFilename)
Parameters
Type |
Name |
Description |
string |
sFilename |
Complete filename including path. Must not be null or an empty string.
|
Exceptions
SaveXml()
Creates a XML string with the current object state.
Declaration
Returns
Type |
Description |
string |
XML string with the object state.
|
SaveXml(string)
Creates a XML string with the current object state.
Declaration
public string SaveXml(string sRootTag)
Parameters
Type |
Name |
Description |
string |
sRootTag |
Root tag to be used in the resulting XML string.
|
Returns
Type |
Description |
string |
XML string with the object state.
|
ToXml(string)
Converts this object into an XML document.
Declaration
public XmlDocument ToXml(string sRootTag)
Parameters
Type |
Name |
Description |
string |
sRootTag |
Root tag to be used in the resulting XML document.
|
Returns
Type |
Description |
XmlDocument |
New instance of XmlDocument.
|
Write(Stream)
Writes object state to the given stream.
Declaration
public void Write(Stream aStream)
Parameters
Type |
Name |
Description |
Stream |
aStream |
Stream to write the object state to. Must not be null and must be
writable. This method does not close the stream after the object state was written
to it. It is up to the caller to ultimately close the stream.
|
Exceptions
WriteXml(XmlWriter)
Callback that is ultimately invoked in order to write the XML representation of
this object.
Declaration
public abstract void WriteXml(XmlWriter aXmlWriter)
Parameters
WriteXmlDocument(XmlWriter)
Declaration
public void WriteXmlDocument(XmlWriter aXmlWriter)
Parameters
WriteXmlDocument(XmlWriter, string)
Declaration
public void WriteXmlDocument(XmlWriter aXmlWriter, string sRootTag)
Parameters
WriteXmlElement(XmlWriter, string, string)
Declaration
protected void WriteXmlElement(XmlWriter aXmlWriter, string sTag, string sValue)
Parameters
WriteXmlElementAcct(XmlWriter, string, FinAcct)
Declaration
protected void WriteXmlElementAcct(XmlWriter aXmlWriter, string sTag, FinAcct aAcct)
Parameters
WriteXmlElementAmt(XmlWriter, string, SwiftAmt)
Declaration
protected void WriteXmlElementAmt(XmlWriter aXmlWriter, string sTag, SwiftAmt tAmt)
Parameters
WriteXmlElementBool(XmlWriter, string, bool)
Declaration
protected void WriteXmlElementBool(XmlWriter aXmlWriter, string sTag, bool fValue)
Parameters
WriteXmlElementDate(XmlWriter, string, SwiftDate)
Declaration
protected void WriteXmlElementDate(XmlWriter aXmlWriter, string sTag, SwiftDate tDate)
Parameters
WriteXmlElementInt(XmlWriter, string, int)
Writes the given integer value, if it is non-zero.
Declaration
protected void WriteXmlElementInt(XmlWriter aXmlWriter, string sTag, int nValue)
Parameters
WriteXmlElementSegment(XmlWriter, string, FinSegment)
Writes the segment as a base 64 encoded string.
Declaration
protected void WriteXmlElementSegment(XmlWriter aXmlWriter, string sTag, FinSegment aSegment)
Parameters
WriteXmlElementTime(XmlWriter, string, SwiftTime)
Declaration
protected void WriteXmlElementTime(XmlWriter aXmlWriter, string sTag, SwiftTime tTime)
Parameters