ConstantExpression Class

From RemObjects Wiki

Jump to:navigation, search
.NET Platform Header-48.png

This is a Data Abstract for .NET Library topic

Please do not modify the page structure, but feel free to modify/add text.

ClassesProtocolsEnums


Contents

Overview

Represents constant values to be used in WhereExpressions.

For example, the following WHERE statement

SELECT * FROM Employees WHERE (Position = 'Sales Manager')

using ConstantExpression would look like this:

WhereExpression lResult;
lResult = new BinaryExpression(
              new FieldExpression("Position"),
              new ConstantExpression("Sales Manager", DataType.String),
              BinaryOperator.Equal),

Location


Properties

Kind

This property is inherited from WhereExpression and gets the expression type. For ConstantExpression, The type is always a WhereKind Constant.


Prism:   property Kind: WhereKind read
C#:   WhereKind Kind { get; }
VB:   Property ReadOnly Kind As WhereKind

Value

Gets or sets the constant value itself.


Prism:   property Value: Object read write
C#:   Object Value { get; set; }
VB:   Property Value As Object


Class Methods

DeserializeObject

Gets the object of the given WhereExpression from the serialized string.


Prism:   class method DeserializeObject(aSourceString: String; aDataType: DataType): Object
C#:   static Object DeserializeObject(String aSourceString, DataType aDataType)
VB:   Shared Function DeserializeObject(aSourceString As String, aDataType As DataType) As Object


Parameters:

  • aSourceString:
  • aDataType:


SerializeObject

Writes the object of the given type to the string.


Prism:   class method SerializeObject(aValue: Object; aDataType: DataType): String
C#:   static String SerializeObject(Object aValue, DataType aDataType)
VB:   Shared Function SerializeObject(aValue As Object, aDataType As DataType) As String


Parameters:

  • aValue:
  • aDataType:



Instance Methods

constructor ()

Default constructor.


Prism:   constructor
C#:   constructor()
VB:   Sub New

constructor (Object)


Prism:   constructor(aValue: Object)
C#:   constructor(Object aValue)
VB:   Sub New (aValue As Object)


Parameters:

  • aValue:


constructor (Object, DataType)


Prism:   constructor(aValue: Object; aType: DataType)
C#:   constructor(Object aValue, DataType aType)
VB:   Sub New (aValue As Object, aType As DataType)


Parameters:

  • aValue:
  • aType:


ReadFromXml

Reads expressions from the XML.



Prism:   method ReadFromXml(aXmlNode: XmlNode)
C#:   void ReadFromXml(XmlNode aXmlNode)
VB:   Sub ReadFromXml(aXmlNode As XmlNode)


Parameters:

  • aXmlNode:


ToSQLString


Prism:   method ToSQLString(aDestination: StringBuilder)
C#:   void ToSQLString(StringBuilder aDestination)
VB:   Sub ToSQLString(aDestination As StringBuilder)


Parameters:

  • aDestination:


WriteToXml

Generates an XML node from the current expression object.


Prism:   method WriteToXml(aXmlNode: XmlNode)
C#:   void WriteToXml(XmlNode aXmlNode)
VB:   Sub WriteToXml(aXmlNode As XmlNode)


Parameters:

  • aXmlNode:



See Also


Da-48.png

Product: RemObjects Data Abstract
Available Editions: Data Abstract for .NET, Delphi and Xcode

GlossaryArchitectureArticlesFeaturesLibrarySamples

Navigation
products
hubs
special
Toolbox