Documentation / @warp-drive/core / types / ModelSchema
Interface: ModelSchema<T>
Defined in: core/src/store/deprecated/-private.ts:139
Minimum subset of static schema methods and properties on the "model" class.
Only used when using the legacy schema-service implementation for @warp-drive/legacy/model or when wrapping schema for legacy Adapters/Serializers.
Type Parameters
T
T = unknown
Methods
eachAttribute()
eachAttribute<K>(callback, binding?): void;Defined in: core/src/store/deprecated/-private.ts:144
Type Parameters
K
K extends string
Parameters
callback
(this, key, attribute) => void
binding?
T
Returns
void
eachRelationship()
eachRelationship<K>(callback, binding?): void;Defined in: core/src/store/deprecated/-private.ts:148
Type Parameters
K
K extends string
Parameters
callback
(this, key, relationship) => void
binding?
T
Returns
void
eachTransformedAttribute()
eachTransformedAttribute<K>(callback, binding?): void;Defined in: core/src/store/deprecated/-private.ts:152
Type Parameters
K
K extends string
Parameters
callback
(this, key, type) => void
binding?
T
Returns
void
Properties
attributes
attributes: Map<KeyOrString<T>, LegacyAttributeField>;Defined in: core/src/store/deprecated/-private.ts:142
fields
fields: Map<KeyOrString<T>, "attribute" | "belongsTo" | "hasMany">;Defined in: core/src/store/deprecated/-private.ts:141
modelName
modelName: T extends TypedRecordInstance ? TypeFromInstance<T<T>> : string;Defined in: core/src/store/deprecated/-private.ts:140
relationshipsByName
relationshipsByName: Map<KeyOrString<T>, LegacyRelationshipField>;Defined in: core/src/store/deprecated/-private.ts:143