dbquery-class
Represents query for building SQL command
public class Korzh.EasyQuery.Db.DbQuery
: Query
Assembly: Korzh.EasyQuery.Db.dll
Constructors
Name | Type | Description |
---|---|---|
DbQuery(DataModel model, Query parentQuery) | void | Initializes a new instance of the Korzh.EasyQuery.Db.DbQuery class. |
DbQuery(DataModel model) | void | Initializes a new instance of the Korzh.EasyQuery.Db.DbQuery class. |
Properties
Name | Type | Description |
---|---|---|
ExtraTables | TableList | Gets the list of "extra" tables (the tables which will be included into result query by user request). |
NoPathResolution | NoPathResolution | Get or set the type of reaction for the situation when two tables have no path between them |
Options | SqlExtras | Gets the Korzh.EasyQuery.Db.SqlExtras object which defines some extra clauses of generated query. |
Methods
Name | Type | Description |
---|---|---|
CheckModelObject(DataModel model) | void | Checks if model object has appropriate type and raise exception if not |
CoreClear() | void | Clears all query content. Can be overriden in derived classes. |
CreateColumn(IColumnDescriptor& modreq(System.Runtime.InteropServices.InAttribute) desc) | QueryColumn | Creates a column by its descriptor |
CreateParentEntityAttrExpr(EntityAttr attr) | EntityAttrExpr | Creates the parent entity attribute expression. |
CreateQueryExpr() | EqExpression | Creates a sub-query expression. |
CreateSubQuery() | Query | Creates the subquery. |
GetParentQueryRootEntity() | Entity | Gets the entities from parent query. |
GetUsedEntities() | List <Entity> | Gets the list of used entities. |
GetUsedTables() | TableList | Gets the used tables. |
LoadNode(XmlReader reader, BitOptions rwOptions) | void | Loads the root node. |
NewModel() | DataModel | Creates a new model (an object of DataModel class or its descendant). |
ReadOnePropFromJsonAsync(JsonReader reader, string propName, BitOptions rwOptions, CancellationToken ct) | Task | Reads the property from JSON reader or skip unused (asynchronous way). |
SaveNodes(XmlWriter writer, BitOptions rwOptions) | void | Saves the root nodes. |
WritePropertiesToJsonAsync(JsonWriter writer, BitOptions rwOptions, CancellationToken ct) | Task | Saves content of the query to JSON (asynchronous way). |