cpl.application

cpl.application.application_abc

class cpl.application.application_abc.ApplicationABC(config: cpl.configuration.configuration_abc.ConfigurationABC, services: cpl.dependency_injection.service_provider_abc.ServiceProviderABC)

Bases: abc.ABC

ABC for the Application class

config: cpl.configuration.configuration_abc.ConfigurationABC

Contains object loaded from appsettings

services: cpl.dependency_injection.service_provider_abc.ServiceProviderABC

Contains instances of prepared objects

abstract configure()

Configure the application

Called by cpl.application.application_abc.ApplicationABC.run

abstract main()

Custom entry point

Called by cpl.application.application_abc.ApplicationABC.run

run()

Entry point

Called by custom Application.main

cpl.application.application_builder

class cpl.application.application_builder.ApplicationBuilder(app: Type[cpl.application.application_abc.ApplicationABC])

Bases: cpl.application.application_builder_abc.ApplicationBuilderABC

This is class is used to build a object of cpl.application.application_abc.ApplicationABC

app: Type[cpl.application.application_abc.ApplicationABC]

Application to build

build()cpl.application.application_abc.ApplicationABC

Creates custom application object

use_startup(startup: Type[cpl.application.startup_abc.StartupABC])

Sets the custom startup class to use

startup: Type[cpl.application.startup_abc.StartupABC]

Startup class to use

cpl.application.application_builder_abc

class cpl.application.application_builder_abc.ApplicationBuilderABC(*args)

Bases: abc.ABC

ABC for the cpl.application.application_builder.ApplicationBuilder

abstract build()cpl.application.application_abc.ApplicationABC

Creates custom application object

abstract use_startup(startup: Type[cpl.application.startup_abc.StartupABC])

Sets the custom startup class to use

startup: Type[cpl.application.startup_abc.StartupABC]

Startup class to use

cpl.application.startup_abc

class cpl.application.startup_abc.StartupABC(*args)

Bases: abc.ABC

ABC for the startup class

abstract configure_configuration()cpl.configuration.configuration_abc.ConfigurationABC

Creates configuration of application

abstract configure_services()cpl.dependency_injection.service_provider_abc.ServiceProviderABC

Creates service provider