import { Module , MiddlewareConsumer , NestModule , Inject } from "@nestjs/common" ; import { DbModule } from "../db" ; import { AuthModule } from "../auth" ; import { ConfigModule } from "../config" ; import { fileProviders } from "./file.providers" ; import { FileController } from "./file.controller" ; import { register as registerTypeMappings } from "./file.type-mappings" ; import { SharedModule , TypeMapperDiToken , TypeMapper } from "../shared" ; /**
 *  File Management abilities.
 *  Providers API for uploading, delete & downloading files.
 *   FileDto - in-system file representation. Reflected in `file` table.
 *   S3FileStorage - S3 based storage class.
 *   PdfFileGeneratorSErvice - API for generating & storing PDF files based on predefined templates.
 *   FileService - High-level API for inernal file-management
  @ Module ( { imports : [ DbModule , AuthModule , SharedModule , ConfigModule , ] , providers : [ ... fileProviders ] , exports : [ ... fileProviders ] , controllers : [ FileController ] , } ) export class FileModule implements NestModule { public constructor ( @ Inject ( TypeMapperDiToken . MAPPER ) private readonly mapper ) { registerTypeMappings ( mapper ) ; } public configure ( consumer ) { } }