oracle.ifs.search
Class PropertyQualification


java.lang.Object

  |

  +--oracle.ifs.search.SearchQualification

        |

        +--oracle.ifs.search.PropertyQualification

All Implemented Interfaces:
java.lang.Cloneable, java.io.Serializable

public class PropertyQualification
extends SearchQualification

The PropertyQualification(PQ) represents a condition on a Class Property. Conecptually PropertyQualifications are similar to AttributeQualifications, with a PQ being applied on an Object's Property instead of an Attribute.

A PropertyQualification is represented by a Search Class, a property Name, a search Value and a comparison operator. The comparison value must be specified as a AttributeValue. For late Binding, the setlateBound function must be called, with dataType of the property specified. This is required there are no rules for mapping property names to dataTypes. Each object is free to use a property name as it chooses.

Roughly, a PropertyQualification translates to the SQL condition exists (select list of proeprties where name = ' Specified Name' and type = 'Specified Type' and value 'oper' 'Specified Comparison Value'

See Also:
Serialized Form

Constructor Summary
PropertyQualification()
          Constructs a PropertyQualification.
 
Method Summary
 java.lang.String getClassname()
          Returns the search class for this qualification object.
 int getDateComparisonLevel()
          Returns the date comparison level.
 int getLateBoundDataType()
          Get the data type if the qualification is late bound.
 int getOperatorType()
          Gets the operator for this qualification.
 java.lang.String getPropertyName()
          Return the searched property.
 AttributeValue getValue()
          Return the comparison value.
 boolean isCaseIgnored()
          Returns true if this object is set to be case insensitive.
 boolean isLateBound()
          Returns whether Qualification is late bound.
 void setCaseIgnored(boolean value)
          Sets up case sensitive behavior for this object.
 void setClassname(java.lang.String clss)
          Set the Search Classname.
 void setDateComparisonLevel(int df)
          Sets the date comparison value.
 void setLateBoundDataType(int dataType)
          Set Qualification as Late Bound.
 void setOperatorType(int oper)
          Sets the comparision operator.
 void setOperatorType(java.lang.String oper)
          Sets the comparison operator.
 void setPropertyName(java.lang.String name)
          Specify the property used in the condition.
 void setValue(AttributeValue av)
          Sets the comparison value.
 
Methods inherited from class oracle.ifs.search.SearchQualification
clone
 

Constructor Detail


PropertyQualification


public PropertyQualification()
                      throws IfsException
Constructs a PropertyQualification. The Date Comparison Level is set to DATE_COMP_SEC, and the comparison operator is set to EQUAL. There are no defaulst for the propertyName, and Search Class.
Method Detail

setClassname


public void setClassname(java.lang.String clss)
                  throws IfsException
Set the Search Classname.

Class should be a valid iFS PublicObject or SubClass or an Alias. A null class is taken to mean, use the first Result Class of the SearchSpecification.

Parameters:
clss - Search Class.
Throws:
IfsException - if the operation fails
See Also:
SearchClassSpecification

getClassname


public java.lang.String getClassname()
                              throws IfsException
Returns the search class for this qualification object.
Returns:
search class.
Throws:
IfsException - if the operation fails

setPropertyName


public void setPropertyName(java.lang.String name)
                     throws IfsException
Specify the property used in the condition. Property Name cannot be null.
Parameters:
name - name of searched property.

getPropertyName


public java.lang.String getPropertyName()
Return the searched property.
Returns:
searched property.

setValue


public void setValue(AttributeValue av)
              throws IfsException
Sets the comparison value. Irrespective of value, Qualification is assumed not to be late bound. Use setLateBound to specify Qualification as Late Bound. The dataType of the specified AttributeValue is assumed to be the dataType of the property.
Parameters:
av - the comparison value specified as an AttrbuteValue
Throws:
IfsException - 22002 if av is null.

getValue


public AttributeValue getValue()
Return the comparison value.
Returns:
comparison value.

setLateBoundDataType


public void setLateBoundDataType(int dataType)
                          throws IfsException
Set Qualification as Late Bound. The dataType of the property needs to be specified. Note there are no rules for mapping property names to datatypes. A property name can be used by different objects to mean differen things.
Parameters:
dataType - property's dataType
Throws:
IfsException - if the operation fails

getLateBoundDataType


public int getLateBoundDataType()
                         throws IfsException
Get the data type if the qualification is late bound. If the qualification is not late bound, it throws IfsException.
Returns:
data type of this qualification if it is late bound
Throws:
IfsException - if the operation fails

isLateBound


public boolean isLateBound()
Returns whether Qualification is late bound.
Overrides:
isLateBound in class SearchQualification
Returns:
whether Qualification is late bound.

setOperatorType


public void setOperatorType(java.lang.String oper)
                     throws IfsException
Sets the comparison operator.
Parameters:
oper - comparison operator string
Throws:
IfsException - if specified operator is not supported.
See Also:
AttributeQualification

setOperatorType


public void setOperatorType(int oper)
                     throws IfsException
Sets the comparision operator.
Parameters:
oper - comaprison operator must be one of, AttributeQualification.EQUAL , AttributeQualification.GREATER_THAN , AttributeQualification.GREATER_THAN_EQUAL , AttributeQualification.IS_NOT_NULL , AttributeQualification.IS_NULL , AttributeQualification.LESS_THAN , AttributeQualification.LESS_THAN_EQUAL , AttributeQualification.LIKE
Throws:
IfsException - if specified operator is not supported.
See Also:
AttributeQualification

getOperatorType


public int getOperatorType()
                    throws IfsException
Gets the operator for this qualification.
Returns:
the operator of the Qualification.

setDateComparisonLevel


public void setDateComparisonLevel(int df)
                            throws IfsException
Sets the date comparison value. The default is DATE_COMP_SEC. If df is not valid, date comparison level is set to the default.
Parameters:
df - date comparison level. See DATE constants for a list of levels.
See Also:
AttributeQualification

setCaseIgnored


public void setCaseIgnored(boolean value)
                    throws IfsException
Sets up case sensitive behavior for this object. If the value is true search with respect to this qualification will ignore case. Default behavior is case sensitive.
Throws:
IfsException - if the operation fails

getDateComparisonLevel


public int getDateComparisonLevel()
Returns the date comparison level.
Returns:
date comparison level.

isCaseIgnored


public boolean isCaseIgnored()
Returns true if this object is set to be case insensitive.
Returns:
boolean True or False.