import { Request, Response } from "lambda-api"; import { JsonPatch } from "../model/JsonPatch"; import { ILogger } from "../util/logging/ILogger"; /** * Base class for API controllers. Provides access to the * current HTTP context as protected fields, and convenience * method for applying JSON patches. */ export declare abstract class Controller { /** * Logger instance for this controller. */ protected _logger: ILogger; /** * The current HTTP request context. */ protected request: Request; /** * The current HTTP response context. */ protected response: Response; setLogger(logger: ILogger): void; setRequest(request: Request): void; setResponse(response: Response): void; /** * Apply a set of JSON patch operations to an * object instance. * * @param T The type of object to be patched. * @param patch The operations to apply. * @param obj The object instance to apply operations to. */ protected applyJsonPatch(patch: JsonPatch, obj: T): T; }