import {Singleton, Instantiable, Inject} from '../../di' import {Collection} from '../../util' import {CommandLineApplication} from './CommandLineApplication' import {Directive} from '../Directive' import {Template} from '../Template' import {templateDirective} from '../templates/directive' import {templateUnit} from '../templates/unit' import {templateController} from '../templates/controller' import {templateMiddleware} from '../templates/middleware' import {templateRoutes} from '../templates/routes' import {templateConfig} from '../templates/config' import {Unit} from '../../lifecycle/Unit' import {Logging} from '../../service/Logging' /** * Service for managing directives, templates, and other resources related * to the command line utilities. */ @Singleton() export class CommandLine extends Unit { @Inject() protected readonly logging!: Logging /** Directive classes registered with the CLI command. */ protected directives: Collection> = new Collection>() /** Templates registered with the CLI command. These can be created with the TemplateDirective. */ protected templates: Collection