import { ValidationResult, EntityService } from "@calf/common"; import { ActivatedRoute, ParamMap } from "@angular/router"; import { OnDestroy, OnInit } from "@angular/core"; import { Serializable } from "@calf/serializable"; import { Subscriber } from "../classes/subscriber.class"; /** * Angular detail page */ export declare abstract class DetailPage implements OnInit, OnDestroy { protected service: EntityService; /** * Current route */ protected abstract route: ActivatedRoute; /** * Subscriber */ protected readonly subscriber: Subscriber; /** * Object identifier in route */ protected identifier: string; /** * Constructor * @param service */ constructor(service: EntityService); /** * On init hook */ ngOnInit(): void; /** * On destroy hook */ ngOnDestroy(): void; /** * On detail hook * @param params */ protected onDetail(params: ParamMap): Promise; /** * Get entity * @param entity */ protected get(entity: TEntity): Promise; /** * On did get hook * @param validation */ protected abstract onDidGet(validation: ValidationResult): Promise; }