Skip navigation links

Oracle Content Services Web Services Java API Reference
10g Release 1 (10.1.2.3)

B25584-03


oracle.ifs.fdk
Class SearchExpression

java.lang.Object
  extended byoracle.ifs.fdk.SearchExpression

All Implemented Interfaces:
java.io.Serializable

public class SearchExpression
extends java.lang.Object
implements java.io.Serializable

This class represents a search expression in the form of an expression tree. Each node in the tree is an instance of this class and represents an operator, a left operand and a right operand.

For AND and OR operators, the left and right operands must both be instances of this class. For the NOT operator, the right operand must be an instance of this class and the left operand must be null.

For comparison operators, the left operand is the name of the attribute being compared represented as a String, and the right operand is the value being compared represented as a String, Integer, Long, Boolean or Date.

The EQUALS operator supports the use of * and ? as wildcard characters. Wildcard characters are only allowed when comparing a String data type. Other operators treat the * and ? characters as literal characters and not as wildcard characters.

The CONTAINS operator does a text search on the contents of a document. The right operand specifies words or phrases to be found in the contents of a document. Words are separated by spaces and phrases are enclosed in double quotes("). The left operand must be null.

The allowable search expression operators are:

Only a subset of FDK attributes are supported in a search expression. See the list of supported attributes below. In addition, some attributes only apply to Documents. Using an attribute that only applies to a Document in a search expression will result in only Documents being returned in the search results. For example, searching on SIZE will result in only Documents (and not Folders) being returned.

The allowable attributes in a search expression are:

Category attributes may be used in a search expression to search for documents with a category associated with the document where the category has an attribute which satisfies the search condition. A category attribute is specified by a string in the format
"[ category_class_name : category_attribute_name ]"

The category_class_name is the internal class name of the category which is different from the category display name. The internal class name of a category is returned by the Attributes.CLASS_NAME attribute of the CATEGORY_CLASS item corresponding to the category.

The category_attribute_name is the internal attribute name of the category attribute which is different from the attribute display name. The internal attribute name corresponds to the Attributes.ATTRIBUTE_NAME value returned by making a subrequest on Attributes.METADATA_ATTRIBUTES.

The special operator HAS_CATEGORY may be used to check if a document has a category of the specified type associated with it. The right operand specifies the category class and the left operand must be null. The right operand is a string in the format
"[ category_class_name ]"

The category_class_name is the internal class name of the category. The HAS_CATEGORY operator will check if a document has the specified category class, or any of the category's subclasses, associated with the document.


Constructor Summary
SearchExpression()
          Constructor.

 

Method Summary
 java.lang.Object getLeftOperand()
          Get the left operand.
 java.lang.String getOperator()
          Get the operator value.
 java.lang.Object getRightOperand()
          Get the right operand.
 void setLeftOperand(java.lang.Object left)
          Set the left operand.
 void setOperator(java.lang.String operator)
          Set the operator value.
 void setRightOperand(java.lang.Object right)
          Set the right operand.
 java.lang.String toString()
          Convert the search expression to a string representation.

 

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

 

Constructor Detail

SearchExpression

public SearchExpression()
Constructor.

Method Detail

getOperator

public java.lang.String getOperator()
Get the operator value.

setOperator

public void setOperator(java.lang.String operator)
Set the operator value.

getLeftOperand

public java.lang.Object getLeftOperand()
Get the left operand.

setLeftOperand

public void setLeftOperand(java.lang.Object left)
Set the left operand.

getRightOperand

public java.lang.Object getRightOperand()
Get the right operand.

setRightOperand

public void setRightOperand(java.lang.Object right)
Set the right operand.

toString

public java.lang.String toString()
Convert the search expression to a string representation.

Skip navigation links

Oracle Content Services Web Services Java API Reference
10g Release 1 (10.1.2.3)

B25584-03


Copyright © 2002, 2005, Oracle. All rights reserved.