import { Router } from "express" ; import { CustomerController } from "./controller/customer.controller" ; import { AppRoute } from "./app-route" ; import { DocumentController } from "./controller/document.controller" ; export class AppRouting { constructor ( private route ) { this . route = route ; this . configure ( ) ; } public configure ( ) { this . addRoute ( new CustomerController ( ) ) ; this . addRoute ( new DocumentController ( ) ) ; } private addRoute ( appRoute ) { this . route . use ( appRoute . route , appRoute . router ) ; } }