1 | import { Model, RelationDefinitionMap } from '../model';
|
2 | export declare const RELATIONS_KEY = "loopback:relations";
|
3 | /**
|
4 | * Decorator for relations
|
5 | * @param definition
|
6 | * @returns A property decorator
|
7 | */
|
8 | export declare function relation(definition?: Object): PropertyDecorator;
|
9 | /**
|
10 | * Get metadata of all relations defined on a given model class.
|
11 | *
|
12 | * @param modelCtor - The model class (the constructor function).
|
13 | * @returns A map of relation definitions
|
14 | */
|
15 | export declare function getModelRelations(modelCtor: typeof Model): RelationDefinitionMap;
|
16 | /**
|
17 | * Decorator for embedsOne
|
18 | * @param definition
|
19 | * @returns A property decorator
|
20 | */
|
21 | export declare function embedsOne(definition?: Object): PropertyDecorator;
|
22 | /**
|
23 | * Decorator for embedsMany
|
24 | * @param definition
|
25 | * @returns A property decorator
|
26 | */
|
27 | export declare function embedsMany(definition?: Object): PropertyDecorator;
|
28 | /**
|
29 | * Decorator for referencesOne
|
30 | * @param definition
|
31 | * @returns A property decorator
|
32 | */
|
33 | export declare function referencesOne(definition?: Object): PropertyDecorator;
|