Class Query
represents a query: e.g.: In
From X In SomeTable Where X.BeginTime > #2012-10-10 12:00:00# Select X With VersionInfoOnly
Alias will map to "X", Source will map to "SomeTable", Where will map to "X.BeginTime > #2012-10-10 12:00:00#", Select will map to "X", QueryOptions will have VersionInfoOnly set to true.
Inherited Members
Namespace: TimeCockpit.Data.QueryLanguage.Syntax
Assembly: TimeCockpit.Data.dll
Syntax
public class Query : Expression
Constructors
Query(String, QuerySource, Expression, OrderBy, Select, QueryOptions)
Initializes a new instance of the Query class.
Declaration
public Query(string alias, QuerySource source, Expression whereCondition, OrderBy orderBy, Select select, QueryOptions queryOptions)
Parameters
Type | Name | Description |
---|---|---|
System.String | alias | The alias of the item. |
QuerySource | source | The source to select from. |
Expression | whereCondition | The where condition. |
OrderBy | orderBy | The order by clause. |
Select | select | The select clause. |
QueryOptions | queryOptions | The query options. |
Query(String, QuerySource, Expression, OrderBy, SkipAndTake, Select, QueryOptions)
Initializes a new instance of the Query class.
Declaration
public Query(string alias, QuerySource source, Expression whereCondition, OrderBy orderBy, SkipAndTake skipAndTake, Select select, QueryOptions queryOptions)
Parameters
Type | Name | Description |
---|---|---|
System.String | alias | The alias of the item. |
QuerySource | source | The source to select from. |
Expression | whereCondition | The where condition. |
OrderBy | orderBy | The order by clause. |
SkipAndTake | skipAndTake | The skip and take clause. |
Select | select | The select clause. |
QueryOptions | queryOptions | The query options. |
Properties
Alias
Gets the alias of the query.
Declaration
public string Alias { get; }
Property Value
Type | Description |
---|---|
System.String |
OrderBy
Gets the order by clause.
Declaration
public OrderBy OrderBy { get; }
Property Value
Type | Description |
---|---|
OrderBy |
QueryOptions
Gets the query options.
Declaration
public QueryOptions QueryOptions { get; }
Property Value
Type | Description |
---|---|
QueryOptions |
Select
Gets the select statement.
Declaration
public Select Select { get; }
Property Value
Type | Description |
---|---|
Select |
SkipAndTake
Gets the skip and take clause.
Declaration
public SkipAndTake SkipAndTake { get; }
Property Value
Type | Description |
---|---|
SkipAndTake |
Source
Gets the query source.
Declaration
public QuerySource Source { get; }
Property Value
Type | Description |
---|---|
QuerySource |
WhereCondition
Gets the where condition.
Declaration
public Expression WhereCondition { get; }
Property Value
Type | Description |
---|---|
Expression |
Methods
Accept(Visitor)
Dispatches to the correct VisitQuery(Query) call.
Declaration
public override Node Accept(Visitor visitor)
Parameters
Type | Name | Description |
---|---|---|
Visitor | visitor | the visitor to dispatch to. |
Returns
Type | Description |
---|---|
Node | Returns the value returned by the call to VisitQuery(Query). |
Overrides
ToTCQL()
Converts the query to TCQL text.
Declaration
public string ToTCQL()
Returns
Type | Description |
---|---|
System.String | Returns the TCQL textual represenation of the query. |