Skip to content

DbEntityAttr class

Base attribute of SQL entity

public class Korzh.EasyQuery.Db.DbEntityAttr
: EntityAttr, IComparable<EntityAttr>
TypeNameDescription
StringEntityPropNameGet or sets property name associated with the attribute (for models loaded from .edmx files)
BooleanIsQuotedGets or sets a value indicating whether corresponding field name should be quoted in result SQL statement.
TableListTablesGets the list of the tables used in this attribute.
BooleanUseAliasGets or sets a value indicating whether it’s necessary to use alias for columns based on this attribute.
TypeNameDescription
voidAddParamsTo(QueryParamList prms)Adds the parameters associated with some entity attribute into the list of query parameters (see Korzh.EasyQuery.QueryParamList.
BooleanCompareWithExpr(String expr)Compares attribute’s expression with the one passed in the parameter.
voidCopyFrom(EntityAttr attr)Copies all attribute’s properties from another entity attribute
StringGetDataAttrFullExpr()Gets a string that represents full expression of EntityAttr instance.
StringGetSqlExpr(DbQueryFormats formats)Gets the SQL expression which represents the attribute.
StringGetSqlName(DbQueryFormats formats, Boolean includeTableName = True)Gets the full SQL name which represents the attribute.
BooleanHasParams()Determines whether this attribute has query parameters.
voidLoadAttribute(String propname, String propvalue)Loads the attribute.
voidLoadNodes(XmlReader reader)Loads the sub-nodes of entity attribute’s node.
voidOnModelAssignment()Called when attribute is inserted into model.
voidProcessVirtualExpr()Scans attribute’s expression for new parameters, tables, etc
voidReadPropertyFromJson(JsonReader reader, String propName)Reads one attribute’s property from JSON.
TaskReadPropertyFromJsonAsync(JsonReader reader, String propName)Reads one attribute’s property from JSON (asynchronous way).
voidSaveXmlAttributes(XmlWriter writer)Saves the attributes to XML writer.
voidWritePropertiesToJson(JsonWriter writer, ModelReadWriteOptions rwOptions)Writes attribute’s properties to JSON.
TaskWritePropertiesToJsonAsync(JsonWriter writer, ModelReadWriteOptions rwOptions)Writes attribute’s properties to JSON (asynchronous way).