Interface Identity

  • All Known Implementing Classes:
    AMIdentity

    public interface Identity
    Models an identity. Makes no guarantee that the underlying identity actually exists.
    • Method Detail

      • asUniversalId

        UniversalId asUniversalId()
        Return the universal id which represents this identity
        Returns:
        The universal id which represents this identity
      • getSSOToken

        SSOToken getSSOToken()
        Get the SSOToken which should be used to authorize operations against this identity.
        Returns:
        The token to use for authorization
      • getAttributes

        Map<String,​Set<String>> getAttributes()
                                             throws IdRepoException,
                                                    SSOException
        Returns all attributes and values of this identity. This method is only valid for Identity objects of type User, Agent, Group, and Role.
        Returns:
        Map of attribute-values
        Throws:
        IdRepoException - If there are repository related error conditions
        SSOException - If user's single sign on token is invalid
      • getAttributes

        Map<String,​Set<String>> getAttributes​(Set<String> attrNames)
                                             throws IdRepoException,
                                                    SSOException
        Returns requested attributes and values of this object.

        This method is only valid for Identity object of type User, Agent, Group, and Role.

        Parameters:
        attrNames - Set of attribute names to be read
        Returns:
        Map of attribute-values
        Throws:
        IdRepoException - If there are repository related error conditions
        SSOException - If user's single sign on token is invalid
      • getAttribute

        Set<String> getAttribute​(String attrName)
                          throws IdRepoException,
                                 SSOException
        Returns the values of the requested attribute. Returns an empty set, if the attribute is not set in the object.

        This method is only valid for Identity objects of type User, Agent, Group, and Role.

        Parameters:
        attrName - Name of attribute
        Returns:
        Set of attribute values
        Throws:
        IdRepoException - if there are repository related error conditions
        SSOException - If user's single sign on token is invalid
      • isExists

        boolean isExists()
                  throws IdRepoException,
                         SSOException
        This method determines if the identity exists and returns true or false.

        This method is only valid for Identity objects of type User and Agent.

        Returns:
        true if the identity exists or false otherwise
        Throws:
        IdRepoException - If there are repository related error conditions
        SSOException - If user's single sign on token is invalid