1 | import { Entity } from '../../model';
|
2 | import { EntityCrudRepository } from '../../repositories';
|
3 | import { Getter, HasManyDefinition, InclusionResolver } from '../relation.types';
|
4 | /**
|
5 | * Creates InclusionResolver for HasMany relation.
|
6 | * Notice that this function only generates the inclusionResolver.
|
7 | * It doesn't register it for the source repository.
|
8 | *
|
9 | * Notice: scope field for inclusion is not supported yet.
|
10 | *
|
11 | * @param meta - resolved metadata of the hasMany relation
|
12 | * @param getTargetRepo - target repository i.e where related instances are
|
13 | */
|
14 | export declare function createHasManyInclusionResolver<Target extends Entity, TargetID, TargetRelations extends object>(meta: HasManyDefinition, getTargetRepo: Getter<EntityCrudRepository<Target, TargetID, TargetRelations>>): InclusionResolver<Entity, Target>;
|