Skip navigation links

Oracle Fusion Middleware Management Java API Reference for Oracle Entitlements Server
11g Release 1 (11.1.1)

E22649-02 ESAPI


oracle.security.jps.service.policystore.search
Class FunctionSearchQuery

java.lang.Object
  extended by oracle.security.jps.search.SearchQuery
      extended by oracle.security.jps.service.policystore.search.BaseSearchQuery
          extended by oracle.security.jps.service.policystore.search.FunctionSearchQuery


public class FunctionSearchQuery
extends BaseSearchQuery

A Class to build search criterias to query Functions.

Following code snippet illustrates how to build a search criteria to search by the DisplayName

  FunctionSearchQuery query = new FunctionSearchQuery( FunctionSearchQuery.SEARCH_PROPERTY.DISPLAY_NAME,
    false, ComparatorType.EQUALITY, "DisplayName Value to searchBy", BaseSearchQuery.MATCHER.EXACT);
  getFunctions ( query );
 

To build more complex search criterias, use the Constructor for complex search query.

Consider the following example to search Functions by a specific description and display name. Obviously, the two criterias (below) have to be AND-ed.

  List<FunctionSearchQuery> list = new ArrayList<FunctionSearchQuery>();
  list.add(new FunctionSearchQuery( FunctionSearchQuery.SEARCH_PROPERTY.DISPLAY_NAME,
    false, ComparatorType.EQUALITY, "The Display Name", BaseSearchQuery.MATCHER.EXACT));
  
  list.add(new FunctionSearchQuery( FunctionSearchQuery.SEARCH_PROPERTY.DESCRIPTION,
    false, ComparatorType.EQUALITY, "The Description", BaseSearchQuery.MATCHER.EXACT));
 
  FunctionSearchQuery query = new FunctionSearchQuery(list, false, false);
 

Similarly, we can have two criterias OR-ed as below.

  List<FunctionSearchQuery> list = new ArrayList<FunctionSearchQuery>();
  list.add(new FunctionSearchQuery( FunctionSearchQuery.SEARCH_PROPERTY.DISPLAY_NAME,
    false, ComparatorType.EQUALITY, "The Display Name", BaseSearchQuery.MATCHER.EXACT));
  
  list.add(new FunctionSearchQuery( FunctionSearchQuery.SEARCH_PROPERTY.DESCRIPTION,
    false, ComparatorType.EQUALITY, "The Description", BaseSearchQuery.MATCHER.EXACT));
 
  FunctionSearchQuery query = new FunctionSearchQuery(list, false, true);
 

Nested Class Summary
static class FunctionSearchQuery.SEARCH_PROPERTY
          Criterias to search Functions By

 

Nested classes/interfaces inherited from class oracle.security.jps.search.SearchQuery
SearchQuery.MATCHER

 

Constructor Summary
FunctionSearchQuery()
           
FunctionSearchQuery(FunctionSearchQuery.SEARCH_PROPERTY property, boolean negation, ComparatorType operator, java.lang.Object valueObject, SearchQuery.MATCHER match)
          Constructor
FunctionSearchQuery(FunctionSearchQuery.SEARCH_PROPERTY property, boolean negation, ComparatorType operator, java.lang.String value, SearchQuery.MATCHER match)
          Constructor
FunctionSearchQuery(java.util.List<FunctionSearchQuery> queries, boolean negation, boolean isORMatch)
          Constructor

 

Method Summary
 FunctionSearchQuery.SEARCH_PROPERTY getSearchByProperty()
          get the search by property in this search query
 FunctionSearchQuery[] getSearchQueryInOrder()
          Get the child search query in this search query.

 

Methods inherited from class oracle.security.jps.service.policystore.search.BaseSearchQuery
getComparator, getQueries, toString

 

Methods inherited from class oracle.security.jps.search.SearchQuery
addBaseQuery, getBaseSearchQueryInOrder, getSearchByPropertyString, getSearchByValue, getSearchByValueObject, getSearchComparator, getSearchQueries, getSearchValueMatch, isANDMatch, isComplexQuery, isNegativeMatch, isORMatch

 

Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait

 

Constructor Detail

FunctionSearchQuery

public FunctionSearchQuery()

FunctionSearchQuery

public FunctionSearchQuery(FunctionSearchQuery.SEARCH_PROPERTY property,
                           boolean negation,
                           ComparatorType operator,
                           java.lang.String value,
                           SearchQuery.MATCHER match)
Constructor
Parameters:
property - the property to search by, See FunctionSearchQuery.SEARCH_PROPERTY for list of valid values
negation - if true, then the NOT operator is applied
operator - the operator to apply
value - the value to search for

If value is null, the match must be ANY

If value is non-null, this value is matched against the values to search for. The match algorithm is applied to values to sarch against.

match - how the value should match-ed with the values to search against. If match is null, an EXACT match is assumed. value should be non-null.

FunctionSearchQuery

public FunctionSearchQuery(FunctionSearchQuery.SEARCH_PROPERTY property,
                           boolean negation,
                           ComparatorType operator,
                           java.lang.Object valueObject,
                           SearchQuery.MATCHER match)
Constructor
Parameters:
property - the property to search by, See FunctionSearchQuery.SEARCH_PROPERTY for list of valid values
negation - if true, then the NOT operator is applied
operator - the operator to apply
valueObject - the value to search for

If value is null, the match must be ANY

If value is non-null, this value is matched against the values to search for. The match algorithm is applied to values to sarch against.

match - how the value should match-ed with the values to search against. If match is null, an EXACT match is assumed. value should be non-null.

FunctionSearchQuery

public FunctionSearchQuery(java.util.List<FunctionSearchQuery> queries,
                           boolean negation,
                           boolean isORMatch)
Constructor
Parameters:
queries - child queries of this query
negation - if true, then the NOT operator is applied.
isORMatch - if true the syntax among the child queries is 'OR', if false, the syntax among child queries is 'AND'

Method Detail

getSearchByProperty

public FunctionSearchQuery.SEARCH_PROPERTY getSearchByProperty()
get the search by property in this search query
Returns:
null if this is a complex search query

getSearchQueryInOrder

public FunctionSearchQuery[] getSearchQueryInOrder()
Get the child search query in this search query. Return child queries for a complex query, return empty arry for a simple query
Returns:

Skip navigation links

Oracle Fusion Middleware Management Java API Reference for Oracle Entitlements Server
11g Release 1 (11.1.1)

E22649-02 ESAPI


Copyright © 2011, Oracle. All rights reserved.