Creates a new repository for the specified repository.
Namespace: log4net.CoreAssembly: log4net (in log4net.dll) Version: 1.2.15.0 (1.2.15.0)
Syntax
Parameters
- repositoryName
- Type: System String
The repository to associate with the ILoggerRepository.
- repositoryType
- Type: System Type
The type of repository to create, must implement ILoggerRepository. If this param is then the default repository type is used.
Return Value
Type: ILoggerRepositoryThe new repository.
Implements
IRepositorySelector CreateRepository(String, Type)Exceptions
Exception | Condition |
---|---|
System ArgumentNullException | repositoryName is . |
log4net.Core LogException | repositoryName already exists. |
Remarks
The ILoggerRepository created will be associated with the repository specified such that a call to [M:GetRepository(string)] with the same repository specified will return the same repository instance.
See Also