Interface PolicyItem.Builder

    • Method Detail

      • policyStoreId

        PolicyItem.Builder policyStoreId​(String policyStoreId)

        The identifier of the PolicyStore where the policy you want information about is stored.

        Parameters:
        policyStoreId - The identifier of the PolicyStore where the policy you want information about is stored.
        Returns:
        Returns a reference to this object so that method calls can be chained together.
      • policyId

        PolicyItem.Builder policyId​(String policyId)

        The identifier of the policy you want information about.

        Parameters:
        policyId - The identifier of the policy you want information about.
        Returns:
        Returns a reference to this object so that method calls can be chained together.
      • policyType

        PolicyItem.Builder policyType​(String policyType)

        The type of the policy. This is one of the following values:

        • static

        • templateLinked

        Parameters:
        policyType - The type of the policy. This is one of the following values:

        • static

        • templateLinked

        Returns:
        Returns a reference to this object so that method calls can be chained together.
        See Also:
        PolicyType, PolicyType
      • policyType

        PolicyItem.Builder policyType​(PolicyType policyType)

        The type of the policy. This is one of the following values:

        • static

        • templateLinked

        Parameters:
        policyType - The type of the policy. This is one of the following values:

        • static

        • templateLinked

        Returns:
        Returns a reference to this object so that method calls can be chained together.
        See Also:
        PolicyType, PolicyType
      • principal

        PolicyItem.Builder principal​(EntityIdentifier principal)

        The principal associated with the policy.

        Parameters:
        principal - The principal associated with the policy.
        Returns:
        Returns a reference to this object so that method calls can be chained together.
      • resource

        PolicyItem.Builder resource​(EntityIdentifier resource)

        The resource associated with the policy.

        Parameters:
        resource - The resource associated with the policy.
        Returns:
        Returns a reference to this object so that method calls can be chained together.
      • actions

        PolicyItem.Builder actions​(Collection<ActionIdentifier> actions)

        The action that a policy permits or forbids. For example, {"actions": [{"actionId": "ViewPhoto", "actionType": "PhotoFlash::Action"}, {"entityID": "SharePhoto", "entityType": "PhotoFlash::Action"}]} .

        Parameters:
        actions - The action that a policy permits or forbids. For example, {"actions": [{"actionId": "ViewPhoto", "actionType": "PhotoFlash::Action"}, {"entityID": "SharePhoto", "entityType": "PhotoFlash::Action"}]} .
        Returns:
        Returns a reference to this object so that method calls can be chained together.
      • actions

        PolicyItem.Builder actions​(ActionIdentifier... actions)

        The action that a policy permits or forbids. For example, {"actions": [{"actionId": "ViewPhoto", "actionType": "PhotoFlash::Action"}, {"entityID": "SharePhoto", "entityType": "PhotoFlash::Action"}]} .

        Parameters:
        actions - The action that a policy permits or forbids. For example, {"actions": [{"actionId": "ViewPhoto", "actionType": "PhotoFlash::Action"}, {"entityID": "SharePhoto", "entityType": "PhotoFlash::Action"}]} .
        Returns:
        Returns a reference to this object so that method calls can be chained together.
      • actions

        PolicyItem.Builder actions​(Consumer<ActionIdentifier.Builder>... actions)

        The action that a policy permits or forbids. For example, {"actions": [{"actionId": "ViewPhoto", "actionType": "PhotoFlash::Action"}, {"entityID": "SharePhoto", "entityType": "PhotoFlash::Action"}]} .

        This is a convenience method that creates an instance of the ActionIdentifier.Builder avoiding the need to create one manually via ActionIdentifier.builder().

        When the Consumer completes, SdkBuilder.build() is called immediately and its result is passed to #actions(List).

        Parameters:
        actions - a consumer that will call methods on ActionIdentifier.Builder
        Returns:
        Returns a reference to this object so that method calls can be chained together.
        See Also:
        #actions(java.util.Collection)
      • definition

        PolicyItem.Builder definition​(PolicyDefinitionItem definition)

        The policy definition of an item in the list of policies returned.

        Parameters:
        definition - The policy definition of an item in the list of policies returned.
        Returns:
        Returns a reference to this object so that method calls can be chained together.
      • createdDate

        PolicyItem.Builder createdDate​(Instant createdDate)

        The date and time the policy was created.

        Parameters:
        createdDate - The date and time the policy was created.
        Returns:
        Returns a reference to this object so that method calls can be chained together.
      • lastUpdatedDate

        PolicyItem.Builder lastUpdatedDate​(Instant lastUpdatedDate)

        The date and time the policy was most recently updated.

        Parameters:
        lastUpdatedDate - The date and time the policy was most recently updated.
        Returns:
        Returns a reference to this object so that method calls can be chained together.
      • effect

        PolicyItem.Builder effect​(String effect)

        The effect of the decision that a policy returns to an authorization request. For example, "effect": "Permit".

        Parameters:
        effect - The effect of the decision that a policy returns to an authorization request. For example, "effect": "Permit".
        Returns:
        Returns a reference to this object so that method calls can be chained together.
        See Also:
        PolicyEffect, PolicyEffect
      • effect

        PolicyItem.Builder effect​(PolicyEffect effect)

        The effect of the decision that a policy returns to an authorization request. For example, "effect": "Permit".

        Parameters:
        effect - The effect of the decision that a policy returns to an authorization request. For example, "effect": "Permit".
        Returns:
        Returns a reference to this object so that method calls can be chained together.
        See Also:
        PolicyEffect, PolicyEffect