TDAParameterExpression

Overview

The TDAParameterExpression class is a descendant of the TDAWhereExpression class defining the name of the parameter in the expression.

Location

 

constructor Create (string, TDADataType)  overload

Creates a new expression of the TDAParameterExpression class with a specified name and data type.

constructor Create(const aParameterName: string; aParameterType: TDADataType)

Parameters:

  • aParameterName: Name of the parameter.
  • aParameterType: Data type of the parameter.

DoValidate  protected    (declared in TDAWhereExpression)

Raised exception if aRaiseException is set

procedure DoValidate(aRaiseException: Boolean; aName: string)

Parameters:

  • aRaiseException: specifies should the exception be raised or not.
  • aName: Name of property

GetWhereKind  protected override

function GetWhereKind: TDAWhereKind

Kind    (declared in TDAWhereExpression)

property Kind: TDAWhereKind read

ParameterName

Name of the parameter.

property ParameterName: string read write

ParameterType

Data type of the parameter.

property ParameterType: TDADataType read write

ParseException  protected    (declared in TDAWhereExpression)

Raises EDAWhereParseXmlException.

procedure ParseException(aName: string)

Parameters:

  • aName: property name.

ParseExpression (IXmlNode, string): TDAWhereExpression  protected overload    (declared in TDAWhereExpression)

Calls ParseException if xr is nil, otherwise calls overload ParseException.

function ParseExpression(xr: IXmlNode; aName: string): TDAWhereExpression

Parameters:

  • xr: source node.
  • aName: Name of property

ParseExpression (IXmlNode): TDAWhereExpression  overload    (declared in TDAWhereExpression)

Creates new Where expression from XML node.

class function ParseExpression(xr: IXmlNode): TDAWhereExpression

Parameters:

  • xr: given XML node.

ReadFromXml  override

Reads where expression from the XML.

procedure ReadFromXml(xr: IXmlNode)

Parameters:

  • xr: source node

RemoveEmptyNodes    (declared in TDAWhereExpression)

class procedure RemoveEmptyNodes(aNode: IXMLNode)

Parameters:

  • aNode:

Validate  override

Validates properties of expression.

procedure Validate

WriteToXml  override

Writes where expression to the XML.

procedure WriteToXml(sw: IXmlNode)

Parameters:

  • sw: destination node

 

Kind    (declared in TDAWhereExpression)

property Kind: TDAWhereKind read

ParameterName

Name of the parameter.

property ParameterName: string read write

ParameterType

Data type of the parameter.

property ParameterType: TDADataType read write

 

ParseExpression (IXmlNode): TDAWhereExpression  overload    (declared in TDAWhereExpression)

Creates new Where expression from XML node.

class function ParseExpression(xr: IXmlNode): TDAWhereExpression

Parameters:

  • xr: given XML node.

RemoveEmptyNodes    (declared in TDAWhereExpression)

class procedure RemoveEmptyNodes(aNode: IXMLNode)

Parameters:

  • aNode:

 

constructor Create (string, TDADataType)  overload

Creates a new expression of the TDAParameterExpression class with a specified name and data type.

constructor Create(const aParameterName: string; aParameterType: TDADataType)

Parameters:

  • aParameterName: Name of the parameter.
  • aParameterType: Data type of the parameter.

DoValidate  protected    (declared in TDAWhereExpression)

Raised exception if aRaiseException is set

procedure DoValidate(aRaiseException: Boolean; aName: string)

Parameters:

  • aRaiseException: specifies should the exception be raised or not.
  • aName: Name of property

GetWhereKind  protected override

function GetWhereKind: TDAWhereKind

ParseException  protected    (declared in TDAWhereExpression)

Raises EDAWhereParseXmlException.

procedure ParseException(aName: string)

Parameters:

  • aName: property name.

ParseExpression (IXmlNode, string): TDAWhereExpression  protected overload    (declared in TDAWhereExpression)

Calls ParseException if xr is nil, otherwise calls overload ParseException.

function ParseExpression(xr: IXmlNode; aName: string): TDAWhereExpression

Parameters:

  • xr: source node.
  • aName: Name of property

ReadFromXml  override

Reads where expression from the XML.

procedure ReadFromXml(xr: IXmlNode)

Parameters:

  • xr: source node

Validate  override

Validates properties of expression.

procedure Validate

WriteToXml  override

Writes where expression to the XML.

procedure WriteToXml(sw: IXmlNode)

Parameters:

  • sw: destination node