StrField class

StrField is a convenience DSL used to construct queries in a concise and understandable way.

Example:

final name = DoubleField('name');
var value = await Find()
        .from('user')
        .where(name.eq('teja'))  // Simplifies query expressions
        .exec(adapter).one();
Inheritance
  • Object
  • Field<String>
  • StrField

Constructors

StrField(String name)

Properties

hashCode → int
The hash code for this object.
read-only, inherited
name → String
Name of the field
final, inherited
runtimeType → Type
A representation of the runtime type of the object.
read-only, inherited
tableName → String
final, inherited

Methods

create(Create statement, { bool isNullable: false, int length: 20, bool primary: false, String foreignTable, String foreignCol, String uniqueGroup }) → void
Adds the field to create statement
like(String value) Cond<String>
Returns a "like" condition [...]
aliasAs(String tableAlias) Field<String>
inherited
between(String low, String high) Between<String>
Returns an "in between" condition [...]
inherited
eq(String value) Cond<String>
Returns an "is equal to" condition [...]
inherited
eqF(String name, { String table }) CondCol<String>
Returns an "is equal to" condition [...]
inherited
eqField(Field<String> rhs) CondCol<String>
Returns an "is equal to" condition [...]
inherited
gt(String value) Cond<String>
Returns a "greater than" condition [...]
inherited
gtEq(String value) Cond<String>
Returns a "greater than equal to" condition [...]
inherited
gtEqF(String name, { String table }) CondCol<String>
Returns a "greater than equal to" condition [...]
inherited
gtEqField(Field<String> rhs) CondCol<String>
Returns a "greater than equal to" condition [...]
inherited
gtF(String name, { String table }) CondCol<String>
Returns a "greater than" condition [...]
inherited
gtField(Field<String> rhs) CondCol<String>
Returns a "greater than" condition [...]
inherited
inBetweenFields(Field<String> low, Field<String> high) InBetweenCol<String>
Returns an "in between" condition
inherited
lt(String value) Cond<String>
Returns a "less than" condition [...]
inherited
ltEq(String value) Cond<String>
Returns a "less than equal to" condition [...]
inherited
ltEqF(String name, { String table }) CondCol<String>
Returns a "less than equal to" condition [...]
inherited
ltEqField(Field<String> rhs) CondCol<String>
Returns a "less than equal to" condition [...]
inherited
ltF(String name, { String table }) CondCol<String>
Returns a "less than" condition [...]
inherited
ltField(Field<String> rhs) CondCol<String>
Returns a "less than" condition [...]
inherited
ne(String value) Cond<String>
Returns a "not equal to" condition [...]
inherited
neF(String name, { String table }) CondCol<String>
Returns a "not equal to" condition [...]
inherited
neField(Field<String> rhs) CondCol<String>
Returns a "not equal to" condition [...]
inherited
noSuchMethod(Invocation invocation) → dynamic
Invoked when a non-existent method or property is accessed.
inherited
set(String value) SetColumn<String>
Returns a "set column" clause [...]
inherited
toString() → String
Returns a string representation of this object.
inherited

Operators

operator %(String other) Cond<String>
This is actually 'like' operator
operator <(String other) Cond<String>
inherited
operator <=(String other) Cond<String>
inherited
operator ==(dynamic other) → bool
The equality operator.
inherited
operator >(String other) Cond<String>
inherited
operator >=(String other) Cond<String>
inherited