EncodingContext class

An encoding context for ConditionEncoder.

Constructors

EncodingContext(String entityName, {Object? parameters, List? positionalParameters, Map<String, Object?>? namedParameters, Transaction? transaction, String? tableName, String? tableFieldID})
EncodingContext.sub(EncodingContext parent)
A sub-context of parent, to encode a part of its condition apart (e.g. in a subquery): its own output, tables aliases (starting with the parent's) and referenced tables, but the same parameters and placeholders (and encoding parameters) as the parent.

Properties

encodingParameters ↔ Map<String, Object?>?
getter/setter pair
entityName ↔ String
The main entity for ConditionEncoder.
getter/setter pair
fieldsReferencedTables → Set<TableFieldReference>
no setter
hashCode → int
The hash code for this object.
no setterinherited
namedParameters ↔ Map<String, Object?>?
getter/setter pair
nullInlinedPlaceholders → Iterable<String>
The keys marked by markPlaceholderInlinedAsNull (in the root context).
no setter
output → StringBuffer
final
outputString → String
no setter
parameters ↔ Object?
getter/setter pair
parametersPlaceholders → Map<String, dynamic>
The encoded parameters placeholders and values (shared with a parent).
final
parent → EncodingContext?
The context of this sub-context, if any (see EncodingContext.sub).
final
positionalParameters ↔ List?
getter/setter pair
referencedTablesFields → Map<String, List<TableFieldReference>>
no setter
relationshipTables → Map<String, TableRelationshipReference>
no setter
root → EncodingContext
The root context (without a parent).
no setter
runtimeType → Type
A representation of the runtime type of the object.
no setterinherited
tableAliases → Map<String, String>
The table aliases used in the encoded output.
final
tableFieldID ↔ String?
getter/setter pair
tableName ↔ String?
getter/setter pair
tableNameOrEntityName → String
no setter
transaction ↔ Transaction?
getter/setter pair

Methods

addEncodingParameter(String suggestedKey, Object? value, {String parameterPrefix = 'param_'}) → String
addFieldReference(TableFieldReference ref, Condition? c) → void
addRelationshipTable(String tableName, TableRelationshipReference relationship, Condition? c) → void
isInnerFieldReference(TableFieldReference ref) → bool
isInnerRelationshipTable(TableRelationshipReference relationship) → bool
isReservedWord(String alias) → bool
isValidAlias(String alias) → bool
markOuterCondition(Condition c) → void
Marks c as needing an outer join (see isInnerFieldReference).
markPlaceholderInlinedAsNull(String parameterKey) → void
Marks parameterKey as having been written as SQL NULL inline (in the root context).
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
parameterValue(ConditionParameter parameter) → Object?
The value of parameter, resolved with all the parameters of this context (parameters, positionalParameters, namedParameters and encodingParameters).
resolveEntityAlias(String entityName) → String
toString() → String
A string representation of this object.
inherited
write(Object o) → void

Operators

operator ==(Object other) → bool
The equality operator.
inherited