Interface IPoliciesClient

Version: 4.0

Contains functionality to get and update policies.

Namespace: StylelabsStylelabs.MSdkClients
Assembly: Stylelabs.M.Sdk.dll
Syntax
RequestResponse
public interface IPoliciesClient

Methods

GetUserGroupPolicyAsync(long)

Gets the policy from specified user group.

Declaration
RequestResponse
Task<IUserGroupPolicy> GetUserGroupPolicyAsync(long userGroupId)
Parameters
TypeNameDescription
longuserGroupId

Id of the user group to get the policy from.

Returns
TypeDescription
Task<>IUserGroupPolicy

The policy or null when it was not found.

GetUserPolicyAsync(long)

Gets the policy from specified user.

Declaration
RequestResponse
Task<IUserPolicy> GetUserPolicyAsync(long userId)
Parameters
TypeNameDescription
longuserId

Id of the user to get the policy from.

Returns
TypeDescription
Task<>IUserPolicy

The policy or null when it was not found.

UpdateAsync(IPolicy)

Updates the specified policy.

Declaration
RequestResponse
Task UpdateAsync(IPolicy policy)
Parameters
TypeNameDescription
IPolicypolicy

The policy to update.

Returns
TypeDescription
Task

An awaitable .

Exceptions
TypeCondition
ValidationException

Thrown when the policy could not be saved because a validation error occurred.

Do you have some feedback for us?

If you have suggestions for improving this article,