|
|
com.architech
|
Inner Class Summary | |
class |
rscSearchCriteria.rscSearch
This class is used internally. |
Field Summary | |
static int |
EXCACT
|
String |
filter
|
static int |
FINAL_STRING
|
static int |
INITIAL_STRING
|
static int |
NOT_STRING
|
static int |
SEARCH_AND
|
static int |
SEARCH_NOT
|
static int |
SEARCH_OR
|
static int |
SUBSTRING
|
Constructor Summary | |
rscSearchCriteria()
|
|
rscSearchCriteria(int matchtype)
|
|
rscSearchCriteria(String name,
int match,
Object value)
|
|
rscSearchCriteria(String criteriaScript,
com.architech.script.scriptEngine engine)
|
Method Summary | |
void |
addCriteria(String name,
int match,
Object value)
Add expression to criteria array. |
void |
addCriteria(String name,
int match,
Object value,
boolean negate)
Add expression to criteria array. |
void |
addTemplate(String name,
int match,
String defvalue)
Add a criteria to the templates array. |
void |
buildCriteria(com.architech.entry.EntryInterface e)
Build the criteria array using provided entry. |
void |
buildCriteriaScript(com.architech.entry.EntryInterface entry)
Call user defined script to build the search filter. |
String |
buildLdapFilter(rscSearchCriteria.rscSearch rs)
Constructs an LDAP search filter from an rscSearch class. |
String |
buildNotesFilter(rscSearchCriteria.rscSearch rs)
Constructs an Notes search filter from an rscSearch class. |
String |
buildNotesFTFilter(rscSearchCriteria.rscSearch rs)
Constructs an Notes FullText search filter from an rscSearch class. |
String |
buildSQLFilter(rscSearchCriteria.rscSearch rs)
Constructs an SQL where expression from an rscSearch class. |
rscSearchCriteria.rscSearch |
getCriteria(int index)
Return criteria class at specified index. |
com.architech.entry.EntryInterface |
getCurrentEntry()
Return the working entry used to generate the criteria array from the templates array. |
int |
getFirstCriteriaMatch()
Return match operator of first criteria entry. |
String |
getFirstCriteriaName()
Return name of first criteria entry. |
String |
getFirstCriteriaValue()
Return value of first criteria entry. |
String |
getLDAPFilter()
Return complete LDAP filter from criteria array. |
String |
getNotesFilter()
Return complete Notes search expression from criteria array. |
String |
getNotesFTFilter()
Return complete Notes FullText search expression from criteria array. |
String |
getScriptFilter()
This method executes a script that returns a user-defined search filter. |
String |
getSearchString(int i)
|
String |
getSimpleFilter()
|
String |
getSQLFilter()
Return complete SQL search expression from criteria array. |
rscSearchCriteria.rscSearch |
getTemplate(int index)
Returns the criteria template at a specific location. |
int |
getType()
Return search type. |
void |
setType(int type)
Set type (SEARCH_AND, SEARCH_OR) for the search criteria. |
int |
size()
Return number of templates. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
public static final int EXCACT
public static final int SUBSTRING
public static final int INITIAL_STRING
public static final int FINAL_STRING
public static final int NOT_STRING
public static final int SEARCH_AND
public static final int SEARCH_OR
public static final int SEARCH_NOT
public String filter
Constructor Detail |
public rscSearchCriteria()
public rscSearchCriteria(int matchtype)
public rscSearchCriteria(String name, int match, Object value)
public rscSearchCriteria(String criteriaScript, com.architech.script.scriptEngine engine)
Method Detail |
public int size()
public rscSearchCriteria.rscSearch getCriteria(int index)
public void addCriteria(String name, int match, Object value)
name
- The attribute namematch
- The match operator (e.g. EXCACT, FINAL_STRING ..)value
- The matching value.public void addCriteria(String name, int match, Object value, boolean negate)
name
- The attribute namematch
- The match operator (e.g. EXCACT, FINAL_STRING ..)value
- The matching value.negate
- Specify true to negate the expressionpublic String getFirstCriteriaName()
public String getFirstCriteriaValue()
public int getFirstCriteriaMatch()
public void setType(int type)
type
- SEARCH_AND, SEARCH_ORpublic int getType()
public rscSearchCriteria.rscSearch getTemplate(int index)
index
- The index into the templates arraypublic void addTemplate(String name, int match, String defvalue)
name
- The attribute namematch
- The match operator (e.g. EXCACT, FINAL_STRING ..)defvalue
- The default valuepublic String buildLdapFilter(rscSearchCriteria.rscSearch rs)
public String buildSQLFilter(rscSearchCriteria.rscSearch rs)
public String buildNotesFilter(rscSearchCriteria.rscSearch rs)
public String buildNotesFTFilter(rscSearchCriteria.rscSearch rs)
public String getLDAPFilter()
public String getSQLFilter()
public String getSimpleFilter()
public String getNotesFilter()
public String getNotesFTFilter()
public String getSearchString(int i)
public com.architech.entry.EntryInterface getCurrentEntry()
Entry
public void buildCriteria(com.architech.entry.EntryInterface e) throws Exception
When the method completes the criteria array has been built so it contains a copy of the templates array with expanded values.
You typically create an instance of this class and then add the templates. Then for each entry you are using in a search you can call the buildCriteria method to populate the criteria array. Then, having done that you can use the getLDAPFilter, getNotesFilter etc to obtain the search filter as a string.
e
- The work entry used in parameter substitutionpublic void buildCriteriaScript(com.architech.entry.EntryInterface entry) throws Exception
entry
- The work entry used in parameter substitutionpublic String getScriptFilter()
|
||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
![]() |
|