public interface CSOSearchManager
Modifier and Type | Method and Description |
---|---|
CSOSearch |
createSearch()
Creates a search object that can be used for keyword and advanced searches.
|
CSOSearchScope |
createSearchScope(java.util.Collection<CentraSiteRegistryObjectType> types)
Creates a CSOSearchScope object from a collection of CSOTypes.
|
CSOSearchScope |
createSearchScope(java.lang.String scopeName)
Creates a search scope based on the given name.
|
CSOSortSpecifier |
createSortSpecifier(CentraSiteObjectAttribute centraSiteObjectAttribute)
Create an instance for
CSOSortSpecifier using the given CentraSiteObjectAttribute. |
CSOSortSpecifier |
createSortSpecifier(CentraSiteObjectAttribute centraSiteObjectAttribute,
CSOSortSpecifier.Direction direction)
Create the instance for CSOSortSpecifier from the given CentraSiteObjectAttribute and Direction.
|
void |
deleteSavedSearch(CSOSearch search)
Deletes a given saved search.
|
void |
deleteSavedSearches(java.util.Collection<CSOSearch> searches)
Deletes the given collection of saved searches.
|
java.util.List<CentraSiteObjectAttribute> |
getCommonAttributes()
Returns the list of common attributes that are configured in System configuration.
|
java.util.List<CentraSiteObjectAttribute> |
getOrganizationAttributes()
Returns set of attributes that are specifically defined for Organization objects.
|
java.util.List<CentraSiteObjectAttribute> |
getPermissionAttributes()
|
java.util.Collection<Category> |
getPhoneTypeCategories()
Returns the collection of phone type taxonomy categories.
|
java.util.Collection<CSOSearch> |
getReportingSearches()
Fetches the collection of saved searches that are marked as report search.
|
java.util.List<CentraSiteObjectAttribute> |
getRoleAttributes()
|
java.util.Collection<CSOSearch> |
getSavedSearches(java.lang.String name)
Loads the collection of saved searches according to the given name.
|
java.util.Collection<CSOSearch> |
getSavedSearches(User user)
Loads the collection of saved searches for a given user.
|
CSOSearchConditionManager |
getSearchConditionManager()
Returns the search condition manager which will be used to create a search condition.
|
java.util.Collection<CSOSearchScope> |
getSearchScopes()
Returns the collection of configured search scopes.
|
java.util.List<CentraSiteObjectAttribute> |
getUserAttributes()
|
boolean |
isSearchKeyExists(java.lang.String name)
Checks whether a search with given name already exists.
|
CSOSearch |
loadSearch(java.lang.String predefinedSearchName)
Creates a CSOSearch object from the given predefined search
name.
|
void |
saveSearch(CSOSearch search)
Saves the given search with the specified name i.e
CSOSearch.getName() . |
void |
saveSearch(CSOSearch search,
boolean overwrite)
Saves the given search with the specified name i.e
CSOSearch.getName() . |
CSOSearch createSearch() throws CLLException
CSOSearch
object for keyword and advanced searchesCLLException
- if CLL fails to create a search objectCSOSearchConditionManager getSearchConditionManager() throws CLLException
CSOSearchConditionManager
for creating a search conditionCLLException
- if CLL fails to return the CSO search condition managerCSOSearchScope createSearchScope(java.lang.String scopeName) throws CLLException
scopeName
- Identifier for the CSOsearchScopeCSOSearchScope
representing the searchScope identified by the scopeName parameterCLLException
- if CLL fails to construct CSOSearchScope from the given nameCSOSearchScope createSearchScope(java.util.Collection<CentraSiteRegistryObjectType> types) throws CLLException
types
- Collection
of CentraSiteRegistryObjectType
s on which the CSOSearchScope is based onCSOSearchScope
representing the collection of CSOTypes passedCLLException
- if CLL fails to construct a CSOSearchScope from the given CSOTypesjava.util.Collection<CSOSearchScope> getSearchScopes() throws CLLException
Collection
of pre-configured CSOSearchScope
sCLLException
- if CLL fails to return the collection of configured search scopesCSOSortSpecifier createSortSpecifier(CentraSiteObjectAttribute centraSiteObjectAttribute) throws CLLException
CSOSortSpecifier
using the given CentraSiteObjectAttribute.
By default, direction is ascending.centraSiteObjectAttribute
- CentraSiteObjectAttribute
for sorting the search resultsCSOSortSpecifier
including the CentraSiteObjectAttributeCLLException
- if CLL fails to construct the CSOSortSpecifier using the given attributeCSOSortSpecifier createSortSpecifier(CentraSiteObjectAttribute centraSiteObjectAttribute, CSOSortSpecifier.Direction direction) throws CLLException
centraSiteObjectAttribute
- CentraSiteObjectAttribute
for sorting the search resultsdirection
- CSOSortSpecifier.Direction
whether ascending or descending; if null, the default is ascending.CSOSortSpecifier
including the CentraSiteObjectAttribute and DirectionCLLException
- if CLL fails to construct the CSOSortSpecifier using the given attribute and directionjava.util.List<CentraSiteObjectAttribute> getCommonAttributes() throws CLLException
List
of common CentraSiteObjectAttribute
s that are configuredCLLException
- if CLL fails to return the list of common attributesjava.util.List<CentraSiteObjectAttribute> getOrganizationAttributes() throws CLLException
List
of CentraSiteObjectAttribute
s defined for OrganizationsCLLException
- If CLL fails to return organization specific attributesjava.util.List<CentraSiteObjectAttribute> getUserAttributes() throws CLLException
List
of User specific CentraSiteObjectAttribute
CLLException
- When an error is encountered trying to retrieve the user attributesjava.util.List<CentraSiteObjectAttribute> getRoleAttributes() throws CLLException
List
of Role specific CentraSiteObjectAttribute
sCLLException
- When an error is encountered trying to retrieve the role attributesjava.util.List<CentraSiteObjectAttribute> getPermissionAttributes() throws CLLException
List
of Permission specific CentraSiteObjectAttribute
sCLLException
- When an error is encountered trying to retrieve the permission attributesjava.util.Collection<CSOSearch> getSavedSearches(User user) throws CLLException
user
- User
whose saved searches have to be obtainedCollection
of applicable saved CSOSearch
instances for the given userCLLException
- If CLL fails to get the user's saved searchsjava.util.Collection<CSOSearch> getSavedSearches(java.lang.String name) throws CLLException
name
- the name of the saved search to retrieveCLLException
- If CLL fails to load the search by namejava.util.Collection<CSOSearch> getReportingSearches() throws CLLException
Collection
of saved CSOSearch
instances marked as report searchCLLException
- if CLL fails to fetch the collection of saved search marked as report searchvoid deleteSavedSearch(CSOSearch search) throws CLLException
search
- Saved CSOSearch
to deleteCLLException
- if CLL fails to delete the saved searchvoid deleteSavedSearches(java.util.Collection<CSOSearch> searches) throws CLLException
searches
- Collection
of saved CSOSearch
instances to deleteCLLException
- if CLL fails to delete the collection of saved searchesvoid saveSearch(CSOSearch search) throws CLLException
CSOSearch.getName()
.
In case the search already exists with the given name, then treat this operation as Update.search
- CSOSearch
object to save.CLLException
- If CLL fails to save the given searchvoid saveSearch(CSOSearch search, boolean overwrite) throws CLLException
CSOSearch.getName()
.
In case the search already exists with the given name, then treat this operation as Update
when overwrite flag is set otherwise reject the savesearch
- CSOSearch
object to save.overwrite
- If true, then overwrites the search if it already exists and
if false, then the save is rejected if it already existsCLLException
- If CLL fails to save the given searchboolean isSearchKeyExists(java.lang.String name) throws CLLException
name
- File name of the search without extensionCLLException
- if CLL fails to check if a search with the given name already exists.CSOSearch loadSearch(java.lang.String predefinedSearchName) throws CLLException
predefinedSearchName
- The predefined search name to loadCSOSearch
for the given name; returns null if there are no saved searches for the given name.CLLException
- if CLL fails to return the CSOSearch for the given namejava.util.Collection<Category> getPhoneTypeCategories() throws CLLException
Collection
of Category
(s)CLLException
- if CLL fails to return the phone type categories