import { RequestHandler } from 'express'; import { Response as ExpressResponse, Request as ExpressRequest } from 'express'; import { Models as ModelsNg2Rest } from 'ng2-rest'; import 'rxjs/add/operator/map'; export declare namespace Models { export import Rest = ModelsNg2Rest; type ContextENDPOINT = { target: Function; initFN: Function; }; type FormlyFromType = 'material' | 'bootstrap'; type ExpressContext = (req: ExpressRequest, res: ExpressResponse) => T; type SyncResponse = string | T; type ResponseFuncOpt = { limitSize?: (enties: Function | Function[], include: string[], exclude: string[]) => void; }; type SyncResponseFunc = (options?: ResponseFuncOpt) => SyncResponse; type MixResponse = SyncResponse | ExpressContext; interface ClientAction { received?: Rest.PromiseObservableMix>; } interface __Response { send?: MixResponse; } interface AsyncResponse { (req?: ExpressRequest, res?: ExpressResponse): Promise | SyncResponseFunc>; } type Response = (__Response | AsyncResponse) & ClientAction & __Response; class Errors { message: string; private code; toString: () => string; private constructor(); private static create; static entityNotFound(entity?: Function): Errors; static custom(message: string, code?: ModelsNg2Rest.HttpCode): Errors; } interface GlobalNpmDependency { name: string; installName?: string; version?: string | number; } interface GlobalCommandLineProgramDependency { name: string; website: string; version?: string; } interface GlobalDependencies { npm?: GlobalNpmDependency[]; programs?: GlobalCommandLineProgramDependency[]; } interface AuthCallBack { (methodReference: Function): RequestHandler; } type InlinePkg = { isIsomorphic: boolean; realName: string; }; }