UNPKG

@chevre/domain

Version:

Chevre Domain Library for Node.js

44 lines (43 loc) 1.81 kB
import { Connection } from 'mongoose'; import * as factory from '../factory'; import eventModel from './mongoose/model/event'; /** * イベントリポジトリー */ export declare class MongoRepository { readonly eventModel: typeof eventModel; constructor(connection: Connection); static CREATE_SCREENING_EVENT_MONGO_CONDITIONS(params: factory.event.screeningEvent.ISearchConditions): any[]; static CREATE_SCREENING_EVENT_SERIES_MONGO_CONDITIONS(params: factory.event.screeningEventSeries.ISearchConditions): any[]; /** * 上映イベントを保管する */ saveScreeningEventSeries(params: { id?: string; attributes: factory.event.screeningEventSeries.IAttributes; }): Promise<factory.event.screeningEventSeries.IEvent>; /** * 上映イベントを保管する */ saveScreeningEvent(params: { id?: string; attributes: factory.event.screeningEvent.IAttributes; }): Promise<factory.event.screeningEvent.IEvent>; countScreeningEvents(params: factory.event.screeningEvent.ISearchConditions): Promise<number>; /** * 上映イベントを検索する */ searchScreeningEvents(params: factory.event.screeningEvent.ISearchConditions): Promise<factory.event.screeningEvent.IEvent[]>; countScreeningEventSeries(params: factory.event.screeningEventSeries.ISearchConditions): Promise<number>; /** * 上映イベントシリーズを検索する */ searchScreeningEventSeries(params: factory.event.screeningEventSeries.ISearchConditions): Promise<factory.event.screeningEventSeries.IEvent[]>; /** * IDでイベントを取得する */ findById<T extends factory.eventType>(params: { typeOf: T; id: string; }): Promise<factory.event.IEvent<T>>; }