BabelFileLicenseProvider
Namespace: Babel.Licensing Assembly: Babel.Licensing.dll
Represents an license provider used to manage licenses stored in a file on disk. This class cannot be inherited.
Inheritance
object ← BabelFileLicenseProvider
Implements
IAsyncLicenseProvider, ILicenseProvider
Inherited Members
object.GetType(), object.MemberwiseClone(), object.ToString(), object.Equals(object?), object.Equals(object?, object?), object.ReferenceEquals(object?, object?), object.GetHashCode()
Constructors
BabelFileLicenseProvider()
Initializes a new instance of the class.
BabelFileLicenseProvider(ILicenseFactory)
Initializes a new instance of the class.
Parameters
Name | Description |
---|---|
| The license factory. |
Exceptions
Name | Description |
---|---|
Thrown when one or more required arguments are null. |
Properties
EnvironmentVariable
Gets or sets the environment variable name that contains the license file path.
Property Value
LicenseFactory
Gets or sets the .
Property Value
LicenseFilePath
Gets or sets the license file full path.
Property Value
LicenseFileSearchDirectories
Gets or sets the directories where to search for a license file.
Property Value
string[]
SignatureProvider
Gets or sets the signature provider
Property Value
Methods
GetLicense(ILicenseContext, Type, object)
When overridden in a derived class, gets a license for an instance or type of component, when given a context and whether the denial of a license throws an exception.
Parameters
Name | Description |
---|---|
| A |
| A |
| An object that is requesting the license. |
Returns
Name | Description |
---|---|
A valid . |
GetLicenseAsync(ILicenseContext, Type, object, CancellationToken)
Gets a license for the specified context, type, and instance asynchronously.
Parameters
Name | Description |
---|---|
| The license context. |
| The type requesting the license. |
| The instance requesting the license. |
| The cancellation token. |
Returns
OnLicenseFileFound(LicenseFileFoundEventArgs)
Raises the license file found event.
Parameters
Name | Description |
---|---|
Event information to send to registered event handlers. |
ValidateLicenseKey(string, ILicenseContext, Type, object)
Validates the license key.
Parameters
Name | Description |
---|---|
| The license key. |
| A |
| A |
| An object that is requesting the license. |
Returns
Name | Description |
---|---|
A valid object. |
LicenseFileFound
Event queue for all listeners interested in LicenseFileFound events.
Event Type
Last updated