ModelIndex class

Describes an index that is created by @primaryKey or @index directive, and is listed in ModelSchemaDefinition.indexes.

Mixed-in types

Constructors

ModelIndex({required List<String> fields, String? name})
const
ModelIndex.fromJson(Map<String, Object?> map)
Create an instance of ModelIndex from a json object
factory

Properties

fields List<String>
An array of field names. The first field is always the field that is annotated by @primaryKey or @index directive , and the remaining fields are the fields specified by sortKeyFields parameter of @primaryKey or @index directive.
final
hashCode int
The hash code for this object.
no setterinherited
name String?
Index name that is defined by the name parameter of @index directive in a model schema. This will always be null when the index is representing @primaryKey directive.
final
props List<Object?>
The type's equatable properties.
no setteroverride
runtimeType Type
A representation of the runtime type of the object.
no setterinherited

Methods

copyWith({List<String>? fields, String? name}) ModelIndex
Make a copy of an existing ModelIndex instance.
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toJson() Map<String, Object?>
Generate a json object that represents ModelIndex
override
toString() String
A string representation of this object.
override

Operators

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