import type { StatusCode } from "../http/index.js"; import type { HttpLayer } from "../layer/index.js"; import type { HttpService } from "../service/index.js"; /** * A layer that sets a specific HTTP status code to the response. * * @example * ```ts * import { StatusCode } from "@taxum/core/http"; * import { SetStatusLayer } from "@taxum/core/middleware/set-status"; * import { m, Router } from "@taxum/core/routing"; * * const router = new Router() * .route("/", m.get(() => "Hello World)) * .layer(new SetStatusLayer(StatusCode.ACCEPTED)); * ``` */ export declare class SetStatusLayer implements HttpLayer { private readonly status; /** * Creates a new {@link SetStatusLayer}. * * @param status - the status to set responses to. */ constructor(status: StatusCode); layer(inner: HttpService): HttpService; }