FoundVariable class
A semantic interpretation of a Variable
in a sql statement.
- Inheritance
-
- Object
- FoundElement
- FoundVariable
- Implemented types
- Available Extensions
Constructors
- FoundVariable({required int index, required String? name, required ColumnType type, required Variable variable, bool nullable = false, bool isArray = false, bool isRequired = false, UsedTypeConverter? typeConverter})
- FoundVariable.nestedQuery({required int index, required String? name, required ColumnType type, required Variable variable, required CapturedVariable? forCaptured})
Properties
- dartParameterName → String
-
no setteroverride
- forCaptured → CapturedVariable?
-
When this variable is introduced for a nested query referencing something
from an outer query, contains the backing variable.
final
- hashCode → int
-
The hash code for this object.
no setterinherited
- hasSqlName → bool
-
no setterinherited
-
If the element should be hidden from the parameter list
final
- index ↔ int
-
The (unique) index of this variable in the sql query. For instance, the
query
SELECT * FROM tbl WHERE a = ? AND b = :xyz OR c = :xyz
contains threeVariable
s in its AST, but only two FoundVariables, where the?
will have index 1 and (both):xyz
variables will have index 2. We only report one FoundVariable per index.getter/setter pair - isArray → bool
-
Whether this variable is an array, which will be expanded into multiple
variables at runtime. We only accept queries where no explicitly numbered
vars appear after an array. This means that we can expand array variables
without having to look at other variables.
final
- isRequired → bool
-
final
- name ↔ String?
-
The name of this variable, or null if it's not a named variable.
getter/setter pairoverride-getter
- nullable → bool
-
Whether the type is nullable in Dart.
final
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
- type → ColumnType
-
The (inferred) type for this variable.
final
- typeConverter → UsedTypeConverter?
-
The type converter to apply before writing this value.
final
- variable → Variable
-
The first
Variable
in the sql statement that has this index.final
Methods
-
dartTypeCode(
[GenerationOptions options = const GenerationOptions()]) → String -
Dart code for a type representing tis element.
override
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
toString(
) → String -
A string representation of this object.
inherited
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited