Class OneComputePlatformClientAuthenticatorBase
Defines the Platform client authenticator base.
Inheritance
System.Object
OneComputePlatformClientAuthenticatorBase
Namespace: DNVGL.One.Compute.Platform.Client.Extensions
Assembly: DNVGL.One.Compute.Platform.Client.Extensions.dll
Syntax
public abstract class OneComputePlatformClientAuthenticatorBase : IOneComputePlatformClientAuthenticator
Constructors
View SourceOneComputePlatformClientAuthenticatorBase(String)
Initializes a new instance of the OneComputePlatformClientAuthenticatorBase class.
Declaration
protected OneComputePlatformClientAuthenticatorBase(string ocpBaseUrl)
Parameters
| Type | Name | Description |
|---|---|---|
| System.String | ocpBaseUrl | The OneCompute REST API URL (base address). |
Properties
View SourceEnableAuthenticationLogging
Gets or sets a value indicating whether logging should be enabled or not, for the authentication process (the default is false).
Declaration
public bool EnableAuthenticationLogging { get; set; }
Property Value
| Type | Description |
|---|---|
| System.Boolean |
OcpBaseUrl
Declaration
public string OcpBaseUrl { get; }
Property Value
| Type | Description |
|---|---|
| System.String |
Methods
View SourceGetAccessTokenAsync()
Declaration
public abstract Task<string> GetAccessTokenAsync()
Returns
| Type | Description |
|---|---|
| Task<System.String> |
Log(String)
Logs an error message.
Declaration
protected void Log(string message)
Parameters
| Type | Name | Description |
|---|---|---|
| System.String | message | The error message to log. |
LogAndThrowAuthenticationFailure(String)
Logs an error message and throws an exception indicating an authentication failure.
Declaration
protected void LogAndThrowAuthenticationFailure(string message)
Parameters
| Type | Name | Description |
|---|---|---|
| System.String | message | The error message to log. |