CAS.Lib.CodeProtect Namespace
CAS.Lib.CodeProtect.LicenseDsc Namespace
CAS.Lib.CodeProtect.LicenseDsc.Constraints Namespace
CAS.Lib.CodeProtect.Properties Namespace
OOI CodeProtect

IsLicensed<(Of <(<'type>)>)> Constructor (Nullable<(Of <(<'Int32>)>)>, Nullable<(Of <(<'TimeSpan>)>)>)

Initializes a new instance of the IsLicensed<(Of <(<'type>)>)> class. It calls TraceFailureReason(String), TraceNoLicenseFile(String), TraceCurrentLicense(LicenseFile) to provide more information about the validation process.

Namespace:  CAS.Lib.CodeProtect
Assembly:  CAS.CodeProtect (in CAS.CodeProtect.dll)

Syntax


public IsLicensed(
	Nullable<int> defaultVolume,
	Nullable<TimeSpan> defaultRunTime
)
Public Sub New ( _
	defaultVolume As Nullable(Of Integer), _
	defaultRunTime As Nullable(Of TimeSpan) _
)
public:
IsLicensed(
	Nullable<int^> defaultVolume, 
	Nullable<TimeSpan^> defaultRunTime
)

Parameters

defaultVolume
Type: Nullable<(Of <(<'Int32>)>)>
The default volume assigned if license does not have valid constrain for the type.
defaultRunTime
Type: Nullable<(Of <(<'TimeSpan>)>)>
The default runtime assigned if license does not have valid constrain for the type.

Remarks


Depending on the situation the constructor calls the virtual methods in the following order:
  • TraceNoLicenseFile(String) - is called only if license file cannot be opened.
  • TraceFailureReason(String) - is called only if license is not valid.
  • TraceCurrentLicense(LicenseFile) - is called if the license is valid.
  • TraceWarning(List<(Of <<'(String>)>>)) - is called only if license is valid and warning is provided.