public class ExistenceQualification extends SearchQualification
//
// Usage Examples
//
// Simple sub query example. Suppose you want to look for,
// All documents whose name appears in STRINGVALUE attribute of any PROPERTY
// Generates query - DOCUMENT.Name in (select STRINGVALUE from PROPERTY)
// This shows scalar attributes on both LHS and RHS.
//
ExistenceQualification eq1 = new ExistenceQualification();
eq1.setLeftAttribute(Document.CLASS_NAME, PublicObject.NAME_ATTRIBUTE);
eq1.setRightAttribute(Property.CLASS_NAME, Property.STRINGVALUE_ATTRIBUTE);
//
// Using the a array type attribute on the right hand side
// Suppose you want to look for, all documents whose name appears in
// STRINGVALUES array type attribute in a property.
// Generates query - DOCUMENT.Name in (select STRINGVALUES[] from PROPERTY)
// This flattens out the array attribute on the right hand side and generates
// a concatenated list of all values in STRINGVALUES attribute in each row.
//
ExistenceQualification eq1 = new ExistenceQualification();
eq1.setLeftAttribute(Document.CLASS_NAME, PublicObject.NAME_ATTRIBUTE);
eq1.setRightAttribute(Property.CLASS_NAME, Property.STRINGVALUES_ATTRIBUTE);
//
// User supplied AttributeValues on the RHS
// Suppose you want to look for documents whose name is in {"FOO", "BAR", "NOTES"},
// then you use the EQ in the following manner.
//
// First generate the list of values.
AttributeValue [] avArray = new AttributeValue[3];
avArray[0] = AttributeValue.newAttributeValue("FOO");
avArray[1] = AttributeValue.newAttributeValue("BAR");
avArray[2] = AttributeValue.newAttributeValue("NOTES");
//
// Then use the list in a EQ.
ExistenceQualification eq1 = new ExistenceQualification();
eq1.setLeftAttribute(Document.CLASS_NAME, PublicObject.NAME_ATTRIBUTE);
eq1.setRightAttributeValue(avArray);
| Modifier and Type | Field and Description |
|---|---|
protected String |
m_LeftAttribute
Holds the Left hand side attribute.
|
protected String |
m_LeftClass
This holds the iFS class name for the left hand side.
|
protected String |
m_RightAttribute
Holds the Right hand side attribute.
|
protected boolean |
m_RightAttributeMV
Holds true if the right hand side is a Multi value attribute.
|
protected Attribute |
m_RightAttributeObject
Holds the actual attribute value representing the right attribute.
|
protected String |
m_RightClass
This holds the iFS class name for the right hand side.
|
protected boolean |
m_StaticType
Holds the type of EQ this is.
|
protected AttributeValue[] |
m_Values
Holds the Attribute Value array supplied by the user.
|
LATE_BIND_OPER| Constructor and Description |
|---|
ExistenceQualification()
Constructs an existence qualification.
|
| Modifier and Type | Method and Description |
|---|---|
protected void |
accept(oracle.ifs.search.SearchQualificationVisitor v)
Accepts a SearchQualificationVisitor.
|
Object |
clone()
Returns a clone of this SearchQualification.
|
String |
getLeftAttributeName()
Gets the left hand side Attribute name.
|
String |
getLeftClassname()
Gets the left hand side class name.
|
protected int |
getRightAttributeDataType()
Gets the data type of the the object on RHS.
|
String |
getRightAttributeName()
Gets the right hand side Attribute name.
|
protected Attribute |
getRightAttributeObject()
Returns the actual attribute object of the RHS.
|
AttributeValue[] |
getRightAttributeValue()
Gets up the Attribute value array for the right hand side.
|
String |
getRightClassname()
Gets the Right hand side class name.
|
protected AttributeValue[] |
getValues()
Returns the AttributeValue array of RHS.
|
protected boolean |
isRightAttributeMV()
Returns true if the right attribute is a MV.
|
boolean |
isRightAttributeValue()
Gets true if the ExistenceQualification was constructed
by supplying an Attribute Value array for RHS.
|
void |
setLeftAttribute(String classname,
String attribute)
Sets the left hand side class and attribute name of this
qualification.
|
protected void |
setLeftClass(String className)
Sets the left hand side class name.
|
void |
setRightAttribute(String classname,
String attribute)
Sets the right hand side class and attribute name of this
qualification.
|
protected void |
setRightAttributeMV(boolean value)
Sets the flag to indicate right attribute is MV.
|
protected void |
setRightAttributeObject(Attribute attr)
Sets the actual attribute corresponding to to the RHS.
|
void |
setRightAttributeValue(AttributeValue[] avArray)
Sets up the Attribute value array for the right hand side.
|
isLateBoundprotected String m_LeftClass
protected String m_RightClass
protected String m_LeftAttribute
protected String m_RightAttribute
protected boolean m_RightAttributeMV
protected transient Attribute m_RightAttributeObject
protected boolean m_StaticType
protected AttributeValue[] m_Values
public ExistenceQualification()
throws IfsException
IfsException - if the operation failspublic void setLeftAttribute(String classname, String attribute) throws IfsException
classname - left hand side class nameattribute - left hand side attribute nameIfsException - if the operation failspublic void setRightAttribute(String classname, String attribute) throws IfsException
classname - right hand side class nameattribute - right hand side attribute nameIfsException - if the operation failspublic void setRightAttributeValue(AttributeValue[] avArray) throws IfsException
avArray - array of attribute valuesIfsException - if the operation failspublic AttributeValue[] getRightAttributeValue() throws IfsException
IfsException - if the operation failspublic String getLeftClassname() throws IfsException
IfsException - if the operation failsprotected void setLeftClass(String className)
public String getRightClassname() throws IfsException
IfsException - if the operation failspublic String getLeftAttributeName() throws IfsException
IfsException - if the operation failspublic String getRightAttributeName() throws IfsException
IfsException - if the operation failsprotected void setRightAttributeMV(boolean value)
value - Value of the flag.protected boolean isRightAttributeMV()
protected void setRightAttributeObject(Attribute attr)
attr - Attribute corresponding to the RHS.protected Attribute getRightAttributeObject()
protected int getRightAttributeDataType()
throws IfsException
IfsExceptionpublic boolean isRightAttributeValue()
throws IfsException
IfsException - if the operation failsprotected AttributeValue[] getValues()
protected void accept(oracle.ifs.search.SearchQualificationVisitor v)
throws IfsException
accept in class SearchQualificationv - SearchQualificationVisitorIfsException - thrown if Visitor code throws.public Object clone()
clone in class SearchQualificationCopyright © 2025. All rights reserved.