Class UserInfoProvider
Provides access to a UserInfo instance returned from a cloud endpoint.
Inherited Members
Namespace: Unity.Cloud.Identity
Syntax
public class UserInfoProvider : IUserInfoProvider
Constructors
UserInfoProvider(IServiceHttpClient, ServiceHostConfiguration)
Provides access to a UserInfo instance returned from a cloud endpoint.
Declaration
public UserInfoProvider(IServiceHttpClient serviceHttpClient, ServiceHostConfiguration serviceHostConfiguration)
Parameters
| Type | Name | Description |
|---|---|---|
| IServiceHttpClient | serviceHttpClient | An IServiceHttpClient instance. |
| ServiceHostConfiguration | serviceHostConfiguration | A service environment configuration. |
Examples
Methods
GetUserInfoAsync()
Retrieves a UserInfo instance from a cloud endpoint.
Declaration
public async Task<UserInfo> GetUserInfoAsync()
Returns
| Type | Description |
|---|---|
| Task<UserInfo> | A task that results in a UserInfo instance after completion. |
Implements
Exceptions
| Type | Condition |
|---|---|
| HttpRequestException | Thrown when the request fails to complete. See the returned StatusCode for more details. |
| UnauthorizedException | |
| ConnectionException | |
| ForbiddenException |