ContainerRegistrar Class

Summary

An ICakeContainerRegistrar that registers services into an IServiceCollection.
Namespace
Cake.Cli
Interfaces
Base Types
  • object
graph BT Type-->Base0["object"] Type-.->Interface0["ICakeContainerRegistrar"] click Interface0 "/api/Cake.Core.Composition/ICakeContainerRegistrar" Type["ContainerRegistrar"] class Type type-node

Syntax

public sealed class ContainerRegistrar : ICakeContainerRegistrar

Constructors

Name Summary
ContainerRegistrar(IServiceCollection) Initializes a new instance of the ContainerRegistrar class.

Methods

Name Value Summary
BuildServiceProvider() ServiceProvider
Transfers pending registrations and builds the service provider.
RegisterInstance<TImplementation>(TImplementation) ICakeRegistrationBuilder
Registers an instance with the container registry.
RegisterType(Type) ICakeRegistrationBuilder
Registers a type with the container registry.
Transfer() void
Transfers pending registrations to the service collection.

Extension Methods

Name Value Summary
AddCakeDiagnostics() ICakeContainerRegistrar
Registers the default Cake diagnostics services.
Dump<ContainerRegistrar>() string
Get a basic string representation of specified object.
Requires the Cake.Incubator addin
IsIn<ContainerRegistrar>(ContainerRegistrar[]) bool
Checks if the source is contained in a list
Requires the Cake.Incubator addin
NotNull<ContainerRegistrar>(string) void
Throws an exception if the specified parameter's value is null.
Requires the Cake.Ftp addin
NotNull<ContainerRegistrar>(string) void
Requires the Cake.Issues addin
RegisterType<TImplementation>() ICakeRegistrationBuilder
Registers a type with the container registrar.
ThrowIfNull<ContainerRegistrar>(string, string) T
Throws a System.ArgumentNullException with a specific message if the value is null, otherwise returns the value
Requires the Cake.Incubator addin
ThrowIfNull<ContainerRegistrar>(string) T
Throws a System.ArgumentNullException if the value is null, otherwise returns the value
Requires the Cake.Incubator addin
ToDictionary() IDictionary<string, object>
Requires the Cake.DeployParams addin
ToStringWithNullMarkup() string
Requires the Cake.Issues addin
UseCakeDefaultModules() ICakeContainerRegistrar
Registers the default Cake modules.