UNPKG

@eclipse-scout/core

Version:
31 lines 1.6 kB
import { Constructor, InitModelOf, ObjectModel, ObjectType, ObjectWithType, Page, PageIdDummyPageParamDo, PageParamDo, Session } from '../../../index'; export declare class PageResolver implements PageResolverModel, ObjectWithType { model: PageResolverModel; session: Session; objectType: string; protected static _INSTANCES: Map<Session, PageResolver>; /** * A map of uuid to objectType of the pages using a {@link PageIdDummyPageParamDo}. */ protected _objectTypeByUuid: Map<string, ObjectType<Page>>; init(model: InitModelOf<this>): void; /** * @returns the object type of the page matching the given page param, or `null` if no such page could be identified. */ findObjectTypeForPageParam(pageParam: PageParamDo): ObjectType<Page>; protected _findObjectTypeForDummyPageParam(pageParam: PageIdDummyPageParamDo): ObjectType<Page>; protected _initObjectTypeByUuid(): void; protected _getPageUuid(PageConstructor: Constructor<Page>): string; /** * Returns an instance of {@link PageResolver} for the given {@link Session}. If no instance is associated * with the session yet, a new instance is created. * * @param session Optional session object. If this is omitted, the first session of the app is used. * If the app does not have any active sessions (e.g. during unit testing), this argument is mandatory. */ static get(session?: Session): PageResolver; } export interface PageResolverModel extends ObjectModel<PageResolver> { session: Session; } //# sourceMappingURL=PageResolver.d.ts.map