1234567891011121314151617181920212223 |
- import { HttpMethod } from './HttpMethod';
- import { HttpHandler } from './HttpHandler';
- import { Request } from './Request';
- import { Response } from './Response';
- abstract class Route extends HttpHandler {
- protected abstract method: HttpMethod;
- protected abstract action: (req: Request, res: Response) => any;
- protected get documentation(): string {
- return '';
- }
- public getMethod(): HttpMethod {
- return this.method;
- }
- public getDocumentation(): string {
- return this.documentation;
- }
- }
- export { Route };
|