Documentation / @ember-data/store / types / ModelSchema
Defined in: packages/store/src/-types/q/ds-model.ts:15
Minimum subset of static schema methods and properties on the "model" class.
Only used when using the legacy schema-service implementation for @ember-data/model or when wrapping schema for legacy Adapters/Serializers.
Type Parameters
T
T
= unknown
Properties
attributes
attributes: Map<KeyOrString<T>, LegacyAttributeField>;
Defined in: packages/store/src/-types/q/ds-model.ts:18
fields
fields: Map<KeyOrString<T>, "attribute" | "belongsTo" | "hasMany">;
Defined in: packages/store/src/-types/q/ds-model.ts:17
modelName
modelName: T extends TypedRecordInstance ? TypeFromInstance<T<T>> : string;
Defined in: packages/store/src/-types/q/ds-model.ts:16
relationshipsByName
relationshipsByName: Map<KeyOrString<T>, LegacyRelationshipField>;
Defined in: packages/store/src/-types/q/ds-model.ts:19
Methods
eachAttribute()
eachAttribute<K>(callback, binding?): void;
Defined in: packages/store/src/-types/q/ds-model.ts:20
Type Parameters
K
K
extends string
Parameters
callback
(this
, key
, attribute
) => void
binding?
T
Returns
void
eachRelationship()
eachRelationship<K>(callback, binding?): void;
Defined in: packages/store/src/-types/q/ds-model.ts:24
Type Parameters
K
K
extends string
Parameters
callback
(this
, key
, relationship
) => void
binding?
T
Returns
void
eachTransformedAttribute()
eachTransformedAttribute<K>(callback, binding?): void;
Defined in: packages/store/src/-types/q/ds-model.ts:28
Type Parameters
K
K
extends string
Parameters
callback
(this
, key
, type
) => void
binding?
T
Returns
void