Table of Contents

Interface IModule

Namespace
Mithril.Core.Abstractions.Modules.Interfaces
Assembly
Mithril.Core.Abstractions.dll

Module interface. Defines a module and initializes it.

public interface IModule
Extension Methods

Properties

Category

Gets the type.

string Category { get; }

Property Value

string

The type.

ContentPath

The content path

string ContentPath { get; }

Property Value

string

The content path.

Features

Gets the features.

IFeature[] Features { get; }

Property Value

IFeature[]

The features.

ID

Gets the identifier.

string ID { get; }

Property Value

string

The identifier.

LastModified

Gets the last modified.

DateTime LastModified { get; }

Property Value

DateTime

The last modified.

Name

Gets the name.

string Name { get; }

Property Value

string

The name.

Order

Gets the order.

int Order { get; }

Property Value

int

The order.

Tags

Gets the tags.

string[] Tags { get; }

Property Value

string[]

The tags.

Version

Gets the version.

string Version { get; }

Property Value

string

The version.

Methods

ConfigureApplication(IApplicationBuilder?, IConfiguration?, IHostEnvironment?)

Configures the application.

IApplicationBuilder? ConfigureApplication(IApplicationBuilder? app, IConfiguration? configuration, IHostEnvironment? environment)

Parameters

app IApplicationBuilder

The application.

configuration IConfiguration

The configuration.

environment IHostEnvironment

The environment.

Returns

IApplicationBuilder

Application builder

ConfigureHostSettings(IHostBuilder?, IConfiguration?, IHostEnvironment?)

Configures the host settings.

IHostBuilder? ConfigureHostSettings(IHostBuilder? host, IConfiguration? configuration, IHostEnvironment? environment)

Parameters

host IHostBuilder

The host.

configuration IConfiguration

The configuration.

environment IHostEnvironment

The environment.

Returns

IHostBuilder

Host builder

ConfigureLoggingSettings(ILoggingBuilder?, IConfiguration?, IHostEnvironment?)

Configures the logging settings.

ILoggingBuilder? ConfigureLoggingSettings(ILoggingBuilder? logging, IConfiguration? configuration, IHostEnvironment? environment)

Parameters

logging ILoggingBuilder

The logging.

configuration IConfiguration

The configuration.

environment IHostEnvironment

The environment.

Returns

ILoggingBuilder

Logging builder

ConfigureMVC(IMvcBuilder?, IConfiguration?, IHostEnvironment?)

Configures the MVC.

IMvcBuilder? ConfigureMVC(IMvcBuilder? mvcBuilder, IConfiguration? configuration, IHostEnvironment? environment)

Parameters

mvcBuilder IMvcBuilder

The MVC builder.

configuration IConfiguration

The configuration.

environment IHostEnvironment

The environment.

Returns

IMvcBuilder

MVC Builder

ConfigureRoutes(IEndpointRouteBuilder?, IConfiguration?, IHostEnvironment?)

Configures the routes.

IEndpointRouteBuilder? ConfigureRoutes(IEndpointRouteBuilder? endpoints, IConfiguration? configuration, IHostEnvironment? environment)

Parameters

endpoints IEndpointRouteBuilder

The endpoints.

configuration IConfiguration

The configuration.

environment IHostEnvironment

The environment.

Returns

IEndpointRouteBuilder

Endpoint route builder

ConfigureServices(IServiceCollection?, IConfiguration?, IHostEnvironment?)

Configures the services for the module.

IServiceCollection? ConfigureServices(IServiceCollection? services, IConfiguration? configuration, IHostEnvironment? environment)

Parameters

services IServiceCollection

The services collection.

configuration IConfiguration

The configuration.

environment IHostEnvironment

The environment.

Returns

IServiceCollection

Services

ConfigureWebHostSettings(IWebHostBuilder?, IConfiguration?, IHostEnvironment?)

Configures the web host settings.

IWebHostBuilder? ConfigureWebHostSettings(IWebHostBuilder? webHost, IConfiguration? configuration, IHostEnvironment? environment)

Parameters

webHost IWebHostBuilder

The web host.

configuration IConfiguration

The configuration.

environment IHostEnvironment

The environment.

Returns

IWebHostBuilder

Web host builder.

InitializeDataAsync(IDataService?, IServiceProvider?)

Initializes the data.

Task InitializeDataAsync(IDataService? dataService, IServiceProvider? services)

Parameters

dataService IDataService

The data service.

services IServiceProvider

The services for the application.

Returns

Task

The async task.

OnStarted()

Called when the application is [started].

void OnStarted()

OnStopped()

Called when the application is [stopped].

void OnStopped()

OnStopping()

Called when the application is [stopping].

void OnStopping()