|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectwt.query.AttributeSearchSpecification
Specifies the basic contract for a database search against an attribute
of a Windchill Persistable object. The template for attribute validation
and SearchCondition construction is specified.
Supported API: false
Extendable: false
Field Summary | |
private String |
attributeName
|
private static String |
CLASSNAME
|
(package private) static char |
DB_SINGLE_WILDCARD
|
(package private) static char |
DB_WILDCARD
|
private boolean |
falseSearch
|
private static Hashtable |
OPERATOR_MAP
|
private static String |
RESOURCE
|
private String |
searchExpression
|
private static char |
SINGLE_EMPTY
|
private static char |
SITE_SINGLE_WILDCARD
|
private static String |
SITE_WILDCARD
|
private Object |
value
|
private static char |
WILDCARD_ESCAPE
|
Constructor Summary | |
AttributeSearchSpecification(String attribute,
String expression)
Construct a search object for the specified attribute. |
Method Summary | |
void |
appendToClassSearchSpec(DefaultClassSearchSpec a_classSearchSpec,
Class a_class)
|
static boolean |
areThereDBWildCards(String value)
|
static boolean |
areThereWildCards(String value)
|
static String |
convertWildcardValue(String attribute_value)
|
private String |
escapeChar(String value,
char db_wildcard,
char escape)
|
private String |
escapeEscape(String value,
String wildcards,
char escape)
|
private static String |
fixWildCards(String value,
char site_wildcard,
char db_wildcard,
char escape)
|
String |
getAttributeName()
Gets the value of the attribute: attributeName; The name of the attribute. |
String |
getQueryName(Class classname)
Return the QUERY_NAME from the introspection on the attribute and class for this AttributeSearchSpecification. |
SearchCondition |
getSearchCondition(Class classname)
Return a SearchCondition for this search object. |
String |
getSearchExpression()
Gets the value of the attribute: searchExpression; The type of search: equal, greater than, less than, and between. |
static SearchExpression |
getSearchExpression(SearchCondition a_searchCondition,
boolean a_falseSearch)
|
String |
getSearchType()
Returns the search expression used by the Persistence Manager for search the database. |
CaseKind |
getStringCase(Class classname)
Return the STRING_CASE from the introspection on the attribute and class for this AttributeSearchSpecification. |
Object |
getValue()
Gets the value of the attribute: value; The value for the attribute to be used in the search criteria. |
boolean |
isFalseSearch()
Gets the value of the attribute: falseSearch; True if the search against this attribute should be a negative search != versus =, >= versus <, etc. |
String |
processWildCards(String in_value)
|
void |
setFalseSearch(boolean a_FalseSearch)
Sets the value of the attribute: falseSearch; True if the search against this attribute should be a negative search != versus =, >= versus <, etc. |
protected void |
setValue(Object a_Value)
Sets the value of the attribute: value; The value for the attribute to be used in the search criteria. |
void |
setValue(String attribute_value)
Set the desired value for the attribute. |
String |
toString()
Return a string dump of the interesting information in this object. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Field Detail |
private static final String RESOURCE
private static final String CLASSNAME
private boolean falseSearch
private Object value
private String attributeName
private String searchExpression
private static final Hashtable OPERATOR_MAP
private static final String SITE_WILDCARD
private static final char SITE_SINGLE_WILDCARD
static final char DB_WILDCARD
static final char DB_SINGLE_WILDCARD
private static final char WILDCARD_ESCAPE
private static final char SINGLE_EMPTY
Constructor Detail |
public AttributeSearchSpecification(String attribute, String expression)
attribute
- Attribute name.expression
- Search expression such as equals.Method Detail |
public boolean isFalseSearch()
public void setFalseSearch(boolean a_FalseSearch) throws WTPropertyVetoException
a_FalseSearch
-
WTPropertyVetoException
public Object getValue()
protected void setValue(Object a_Value) throws WTPropertyVetoException
a_Value
-
WTPropertyVetoException
public String getAttributeName()
public String getSearchExpression()
public void setValue(String attribute_value) throws WTPropertyVetoException
attribute_value
- Value to search for.
WTPropertyVetoException
public String getSearchType()
public SearchCondition getSearchCondition(Class classname) throws WTException, QueryException
classname
- Class to search against.
WTException
QueryException
public String toString()
public String getQueryName(Class classname) throws WTIntrospectionException
classname
- Class to search against.
WTIntrospectionException
public CaseKind getStringCase(Class classname) throws WTIntrospectionException
classname
- Class to search against.
WTIntrospectionException
public void appendToClassSearchSpec(DefaultClassSearchSpec a_classSearchSpec, Class a_class) throws WTException, WTPropertyVetoException
WTException
WTPropertyVetoException
public static SearchExpression getSearchExpression(SearchCondition a_searchCondition, boolean a_falseSearch) throws WTException, WTPropertyVetoException
WTException
WTPropertyVetoException
public static String convertWildcardValue(String attribute_value)
public String processWildCards(String in_value)
private String escapeChar(String value, char db_wildcard, char escape)
private String escapeEscape(String value, String wildcards, char escape)
private static String fixWildCards(String value, char site_wildcard, char db_wildcard, char escape)
public static boolean areThereWildCards(String value)
public static boolean areThereDBWildCards(String value)
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |