Table class

Annotation to configure the table definition of a ManagedObject.

Adding this metadata to a table definition (T in ManagedObject<T>) configures the behavior of the underlying table. For example:

    class User extends ManagedObject<_User> implements _User {}

    @Table(name: "_Account");
    class _User {
      @primaryKey
      int id;

      String name;
      String email;
    }

Constructors

Table({bool useSnakeCaseName = false, String? name, List<Symbol>? uniquePropertySet, bool useSnakeCaseColumnName = false})
Default constructor.
const
Table.unique(List<Symbol> properties)
Configures each instance of a table definition to be unique for the combination of properties.
const

Properties

hashCode → int
The hash code for this object.
no setterinherited
name → String?
The name of the underlying database table.
final
runtimeType → Type
A representation of the runtime type of the object.
no setterinherited
uniquePropertySet → List<Symbol>?
Each instance of the associated table definition is unique for these properties.
final
useSnakeCaseColumnName → bool
Useful to indicate using new snake_case naming convention for columns. This property defaults to false to avoid breaking change ensuring backward compatibility
final
useSnakeCaseName → bool
Useful to indicate using new snake_case naming convention if name is not set This property defaults to false to avoid breaking change ensuring backward compatibility
final

Methods

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