AEProxyColumn Class Reference

A class that models a column reference to any relational expression node. More...

Inherits AETerminalExprT< AEValueExpr >.

List of all members.

Public Member Functions

virtual void AcceptVisitor (AENodeVisitor &in_visitor)
 Calls the correct method on the visitor.
 AEProxyColumn (const AEProxyColumn &in_other)
 Copy constructor.
 AEProxyColumn (SharedPtr< AEValueExpr > in_refValue, AEQueryScope *in_queryScope, AERelationalExpr *in_relExpr=NULL, simba_uint16 in_columnNum=SE_INVALID_COLUMN_NUMBER)
 Constructor.
virtual AEProxyColumnClone () const
 Creates a clone of this node object.
virtual const AEProxyColumnGetAsProxyColumn () const
 Retrieves the object as an AEProxyColumn object.
virtual AEProxyColumnGetAsProxyColumn ()
 Retrieves the object as an AEProxyColumn object.
virtual void GetCatalogName (simba_wstring &out_catalogName) const
 This function returns the Catalog name.
virtual
Simba::DSI::DSICollatingCoercibility 
GetCollatingCoercibility () const
 Gets the collating coercibility of the column.
virtual SharedPtr
< Simba::DSI::ICollation
GetCollation () const
 Gets the collation of the column.
Simba::DSI::IColumnGetColumn () const
 Gets the pointer to the column in the underlying relational expression.
virtual const
Simba::DSI::DSIColumnMetadata
GetColumnMetadata () const
 Gets a reference to the DSIColumnMetadata describing the column.
simba_uint16 GetColumnNum () const
 Returns the column number for this value expression in relation to the relational expression that this value expression references.
virtual simba_uint32 GetColumnSize () const
 Returns the size for the column for character or binary data.
virtual void GetLabel (simba_wstring &out_label) const
 Retrieves the column label.
virtual simba_wstring GetLogString () const
 Returns a string name for this node for the purpose of logging.
ETRelationalExprGetMaterializedRelationalExpr ()
 Gets a pointer reference to the relational expression to which this column references.
virtual SqlTypeMetadataGetMetadata () const
 Returns a SqlTypeMetadata* describing the column.
virtual void GetName (simba_wstring &out_name) const
 Retrieves the column name.
virtual AENodeType GetNodeType () const
 Returns an integer that uniquely identifies the node class. See the definition of AENodeType for values defined.
AEQueryScope * GetQueryScopeResolved ()
 Gets the query scope that this column is resolved.
virtual AEValueExprGetRefVal ()
 Returns the expression that this proxy column refers.
AERelationalExprGetRelationalExpr ()
 Gets a pointer reference to the relational expression to which this column references.
virtual void GetSchemaName (simba_wstring &out_schemaName) const
 This function returns the Schema name.
virtual
Simba::DSI::DSIColumnSearchable 
GetSearchable () const
 Indicates how the column can be used in a WHERE clause.
virtual void GetTableName (simba_wstring &out_tableName) const
 Gets the name of the table.
virtual
Simba::DSI::DSIColumnUpdatable 
GetUpdatable () const
 Describes whether the column is updatable in the result set.
virtual bool IsAutoUnique () const
 Indicates whether the column is auto-incrementing or not.
virtual bool IsCaseSensitive () const
 Indicates whether the column is case sensitive.
virtual Simba::DSI::DSINullable IsNullable () const
 Indicates whether the column may hold null data.
virtual bool IsSortable () const
 Indicates whether the column is sortable.
virtual bool IsUnnamed () const
 Indicates whether the column contains a column alias or name.
void SetMaterializedRelationalExpr (ETRelationalExpr *in_relExpr)
 Sets the relational expression that this column references.
void SetRelationalExpr (AERelationalExpr *in_relExpr)
 Sets the relational expression that this column references.
virtual ~AEProxyColumn ()
 Destructor.

Protected Member Functions

virtual bool IsEqual (const AENode *in_another) const
 Tests whether two nodes are "equal".

Detailed Description

A class that models a column reference to any relational expression node.

AEProxyColumn is similar to AEColumn in the sense that it represents a column reference. It differs from AEColumn in that it can reference any relational expression, not just a named relational expression.

In practice, an AEProxyColumn represents a column that is "artificially" created during the AETree building phase. In other words, it does not have a physical presence in the SQL query in the literal sense.

Will always have no children (GetChildCount() returns 0).


Constructor & Destructor Documentation

AEProxyColumn ( SharedPtr< AEValueExpr in_refValue,
AEQueryScope *  in_queryScope,
AERelationalExpr in_relExpr = NULL,
simba_uint16  in_columnNum = SE_INVALID_COLUMN_NUMBER 
)

Constructor.

Parameters:
in_refValue The expression that this proxy column refers.
in_queryScope The query scope that this proxy column points to. Cannot be NULL. (NOT OWN)
in_relExpr A pointer reference to AERelationalExpr. (NOT OWN)
in_columnNum The column index.
Exceptions:
SEInvalidArgumentException when in_relExpr is _NOT_ NULL and in_columnNum is invalid.
AEProxyColumn ( const AEProxyColumn in_other  ) 

Copy constructor.

To support "cloning". See Clone() method.

Parameters:
in_other The other node to create copy from.
virtual ~AEProxyColumn (  )  [virtual]

Destructor.


Member Function Documentation

virtual void AcceptVisitor ( AENodeVisitor in_visitor  )  [virtual]

Calls the correct method on the visitor.

Parameters:
in_visitor The visiting object.

Implements AENode.

virtual AEProxyColumn* Clone (  )  const [virtual]

Creates a clone of this node object.

Returns:
A clone of this node object. (OWN)

Implements AEValueExpr.

virtual const AEProxyColumn* GetAsProxyColumn (  )  const [virtual]

Retrieves the object as an AEProxyColumn object.

Overrides the method defined in AEValueExpr.

Returns:
This object as an AEProxyColumn object. (NOT OWN)

Reimplemented from AEValueExpr.

virtual AEProxyColumn* GetAsProxyColumn (  )  [virtual]

Retrieves the object as an AEProxyColumn object.

Overrides the method defined in AEValueExpr.

Returns:
This object as an AEProxyColumn object. (NOT OWN)

Reimplemented from AEValueExpr.

virtual void GetCatalogName ( simba_wstring out_catalogName  )  const [virtual]

This function returns the Catalog name.

Parameters:
out_catalogName The output catalog name for the value expression.

Reimplemented from AEValueExpr.

virtual Simba::DSI::DSICollatingCoercibility GetCollatingCoercibility (  )  const [virtual]

Gets the collating coercibility of the column.

Returns:
An enum that specifies the coercibility of the column.

Reimplemented from AEValueExpr.

virtual SharedPtr<Simba::DSI::ICollation> GetCollation (  )  const [virtual]

Gets the collation of the column.

Returns:
The collation of the column.

Reimplemented from AEValueExpr.

Simba::DSI::IColumn* GetColumn (  )  const

Gets the pointer to the column in the underlying relational expression.

Returns:
The pointer to the column in the underlying relational expression. (NOT OWN)
virtual const Simba::DSI::DSIColumnMetadata& GetColumnMetadata (  )  const [virtual]

Gets a reference to the DSIColumnMetadata describing the column.

Returns:
Reference to the DSIColumnMetadata describing the column.

Reimplemented from AEValueExpr.

simba_uint16 GetColumnNum (  )  const [inline]

Returns the column number for this value expression in relation to the relational expression that this value expression references.

Returns:
The column number.
virtual simba_uint32 GetColumnSize (  )  const [virtual]

Returns the size for the column for character or binary data.

For character data, this size should be in terms of the number of characters, not the number of bytes. For example, VARCHAR(10) and NVARCHAR(10) would both correspond to size of 10, even if NVARCHAR used 2 bytes per character.

This method is not used for non-character/binary data types.

Returns:
The size of the column for character or binary data.

Reimplemented from AEValueExpr.

virtual void GetLabel ( simba_wstring out_label  )  const [virtual]

Retrieves the column label.

Parameters:
out_label The output label for the value expression.

Reimplemented from AEValueExpr.

virtual simba_wstring GetLogString (  )  const [virtual]

Returns a string name for this node for the purpose of logging.

Returns:
A string representation of this node.

Implements AENode.

ETRelationalExpr* GetMaterializedRelationalExpr (  )  [inline]

Gets a pointer reference to the relational expression to which this column references.

NOTE: This method is designed solely to assist materialization.

Returns:
a pointer reference to the relational expression to which this column references. (NOT OWN)
virtual SqlTypeMetadata* GetMetadata (  )  const [virtual]

Returns a SqlTypeMetadata* describing the column.

Returns:
SQLTypeMetadata pointer describing the column. (NOT OWN)

Reimplemented from AEValueExpr.

virtual void GetName ( simba_wstring out_name  )  const [virtual]

Retrieves the column name.

Parameters:
out_name The output name for the value expression.

Reimplemented from AEValueExpr.

virtual AENodeType GetNodeType (  )  const [virtual]

Returns an integer that uniquely identifies the node class. See the definition of AENodeType for values defined.

Returns:
The ID that uniquely identifies this type of nodes.

Implements AENode.

AEQueryScope* GetQueryScopeResolved (  )  [inline]

Gets the query scope that this column is resolved.

Returns:
The query scope that this column is resolved. (NOT OWN)
virtual AEValueExpr* GetRefVal (  )  [virtual]

Returns the expression that this proxy column refers.

Returns:
The expression that is proxy column refers. (NOT OWN)
AERelationalExpr* GetRelationalExpr (  )  [inline]

Gets a pointer reference to the relational expression to which this column references.

Returns:
a pointer reference to the relational expression to which this column references. (NOT OWN)
virtual void GetSchemaName ( simba_wstring out_schemaName  )  const [virtual]

This function returns the Schema name.

Parameters:
out_schemaName The output schema name for the value expression.

Reimplemented from AEValueExpr.

virtual Simba::DSI::DSIColumnSearchable GetSearchable (  )  const [virtual]

Indicates how the column can be used in a WHERE clause.

Returns:
The DSIColumnSearchable value describing how the column can be used in a WHERE clause.

Reimplemented from AEValueExpr.

virtual void GetTableName ( simba_wstring out_tableName  )  const [virtual]

Gets the name of the table.

Parameters:
out_tableName The output table name for the value expression.

Reimplemented from AEValueExpr.

virtual Simba::DSI::DSIColumnUpdatable GetUpdatable (  )  const [virtual]

Describes whether the column is updatable in the result set.

This default implementation returns DSI_READ_ONLY.

Reimplemented from AEValueExpr.

virtual bool IsAutoUnique (  )  const [virtual]

Indicates whether the column is auto-incrementing or not.

Returns:
True if the column is auto-incrementing; false otherwise.

Reimplemented from AEValueExpr.

virtual bool IsCaseSensitive (  )  const [virtual]

Indicates whether the column is case sensitive.

Returns:
True if the column is case sensitive; false otherwise.

Reimplemented from AEValueExpr.

virtual bool IsEqual ( const AENode in_another  )  const [protected, virtual]

Tests whether two nodes are "equal".

Two AEProxyColumn's are equal if IsEqualComprehensive() returns true.

Parameters:
in_another Another node to compare to. (NOT OWN)
Returns:
True if two nodes are equal, false otherwise.

Reimplemented from AENode.

virtual Simba::DSI::DSINullable IsNullable (  )  const [virtual]

Indicates whether the column may hold null data.

Returns:
The DSIColumnNullable value, which indicates whether the column may hold null data.

Reimplemented from AEValueExpr.

virtual bool IsSortable (  )  const [virtual]

Indicates whether the column is sortable.

Returns:
True if the column is sortable.

Reimplemented from AEValueExpr.

virtual bool IsUnnamed (  )  const [virtual]

Indicates whether the column contains a column alias or name.

This default implementation return false since most of the value expressions have neither a label nor a name.

Reimplemented from AEValueExpr.

void SetMaterializedRelationalExpr ( ETRelationalExpr in_relExpr  )  [inline]

Sets the relational expression that this column references.

NOTE: This method is designed solely to assist materialization.

Parameters:
in_relExpr The materialized relational expression that this column should reference.
void SetRelationalExpr ( AERelationalExpr in_relExpr  )  [inline]

Sets the relational expression that this column references.

Parameters:
in_relExpr The relational expression that this column references. Cannot be NULL. (NOT OWN)

The documentation for this class was generated from the following file:

Generated on Wed May 17 14:21:17 2017 for SimbaEngine 10.1.3.1011 by simba