Package com.sun.identity.idm
Class IdSearchResults
java.lang.Object
com.sun.identity.idm.IdSearchResults
This class
IdSearchResults
provides to obtain the search
results.-
Field Summary
Modifier and TypeFieldDescriptionprotected int
protected Map<AMIdentity,
Map<String, ?>> protected Set<AMIdentity>
static final int
Code used to indicate that the search was unsuccessful as the size limit exceeded during the search process.static final int
Code used to indicate a successful searchstatic final int
Code used to indicate that the search was unsuccessful as the time limit exceeded during the search process. -
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionvoid
addResult
(AMIdentity id, Map attrs) Adds an AMIdentity object to this search result.int
Method which returns the error code of search.protected String
Optional<org.forgerock.openam.utils.PagingCookieControl>
Get the paging cookie control that contains the cookie to accompany the search results.Map<AMIdentity,
Map<String, ?>> Method which returns the search results as a map containing AMIdentity objects as key and the attribute value String.Method which returns the search results as an ordered set.protected IdType
getType()
void
setErrorCode
(int error) Set the error code for this Search Resultvoid
setPagingCookieControl
(org.forgerock.openam.utils.PagingCookieControl pagingCookieControl) Set the paging cookie control that contains the cookie to accompany the search results.toString()
Returns String representation of theIdSearchResults
object.
-
Field Details
-
SUCCESS
public static final int SUCCESSCode used to indicate a successful search- See Also:
-
SIZE_LIMIT_EXCEEDED
public static final int SIZE_LIMIT_EXCEEDEDCode used to indicate that the search was unsuccessful as the size limit exceeded during the search process.- See Also:
-
TIME_LIMIT_EXCEEDED
public static final int TIME_LIMIT_EXCEEDEDCode used to indicate that the search was unsuccessful as the time limit exceeded during the search process.- See Also:
-
searchResults
-
resultsMap
-
errorCode
protected int errorCode
-
-
Constructor Details
-
IdSearchResults
-
-
Method Details
-
getResultAttributes
Method which returns the search results as a map containing AMIdentity objects as key and the attribute value String. The attribute value is a Set.- Returns:
- Map containing AMIdentity objects as the key and Maps of attribute-valuesof the attributes specified as part of the search. The Maps contains attribute names as keys and Set containing values of those attributes. Returns an empty Map if no attributes were specified as part of search request.
-
getSearchResults
Method which returns the search results as an ordered set.- Returns:
- Set of AMIdentity objects matching the search criteria
-
getErrorCode
public int getErrorCode()Method which returns the error code of search.- Returns:
- Error code of search. The possible values are
SUCCESS
,SIZE_LIMIT_EXCEEDED
andTIME_LIMIT_EXCEEDED
- See Also:
-
addResult
Adds an AMIdentity object to this search result.- Parameters:
id
- AMIdentity representing the entity.attrs
- Map of attrbibutes obtained while performing the search
-
setErrorCode
public void setErrorCode(int error) Set the error code for this Search Result- Parameters:
error
- Error code of Search Result.- See Also:
-
getType
-
getOrgName
-
setPagingCookieControl
@Evolving public void setPagingCookieControl(org.forgerock.openam.utils.PagingCookieControl pagingCookieControl) Set the paging cookie control that contains the cookie to accompany the search results.- Parameters:
pagingCookieControl
- The paging cookie control.
-
getPagingCookieControl
Get the paging cookie control that contains the cookie to accompany the search results.- Returns:
- The optional paging cookie control.
-
toString
Returns String representation of theIdSearchResults
object. It returns identity names and attributes
-