Interface SubjectManager


  • public interface SubjectManager
    Manage subjects (users and roles) in the external security system including searching for users and roles and importing users.
    • Field Detail

      • NO_ADD_WILDCARD_PREFIX

        static final String NO_ADD_WILDCARD_PREFIX
        Add this prefix to a query to indicate that wildcards should not be added
        See Also:
        Constant Field Values
    • Method Detail

      • search

        SubjectSearchResult[] search​(String query,
                                     Set<SubjectType> types,
                                     int fetchSize)
        Search for subjects (users and roles).
        Parameters:
        query - the query to search with, may contain * as a wildcard. If it does not contain any wildcards then wildcards will be added at the start and end unless the query starts with NO_ADD_WILDCARD_PREFIX (NOADDWILDCARD:).
        types - the types of subject to search for, use constants from SubjectSearchResult.
        fetchSize - the maximum fetch size, if greater than zero.
        Returns:
        the subjects found.
      • importUser

        Subject importUser​(String uid,
                           String isolationGroupName)
        Import a user into an isolation group, current user (from the session used to create the SubjectManager) must have the User_Administration privilege grant
        Parameters:
        uid - the user id in the external security system.
        isolationGroupName - the isolation group to import into.
        Returns:
        the imported user.