class: MetadataSearchQuery

public class: MetadataSearchQuery
Author: endres
Project: Phase: 1.0; Status: Proposed; Version: 1.0; Complexity: 1
Dates: Created: 16.07.2009 15:19:47; Modified: 16.07.2009 15:19:47;
Flags: Active: false; IsRoot: false; IsLeaf: false;
Extension Points:
UUID: {AE59FAE5-8EDC-4ea5-B6B8-72ABA404B1C8}
A search query with a set of metadata criteria. The criteria can be combined with logical operators to each other. The first criteria should have no logical operator. The next criteria should define a logical operator to connect to the criteria before.<br/> Per default a search query consists of two types of criteria. A list of contentTypes and a list of other search criteria.
 

Goto: Custom Properties, Fields, Methods

Extends: SearchQuery

See also: SearchQuery

Appears in: query

Connections
 
Custom Properties
 
MetadataSearchQuery Attributes
Attribute Details
private ArrayList
  contentTypes
Initial: null
Notes: List of content types to look for.
private ArrayList
  searchCriteria
Initial: null
Notes: List of search criteria.
private static const long
  serialVersionUID
Initial: 1L
Notes: Serial identifier.
 
MetadataSearchQuery Methods
Operation Details
private
addContentTypeCriterions(
   ArrayList contentT):void
Sequential
Tags: throws=TechnicalException
Notes: Add content type criteria to the query.
public
addCriterion(
   MetadataSearchCriterion criterion):void
Sequential
Notes: Adds a criterion.
private
generateNodeWithCriterion(
   CQLNode node,
   MetadataSearchCriterion criterion):CQLNode
Sequential
Tags: throws=CQLParseException,IOException,ParseException,TechnicalException
Notes: Generate a three node tree with a criterion and a existing node. The existing node will be attached to a newly created node and a new root node above the two will be returned.
@return root node of the two node tree
public
getCqlNode():CQLNode
Sequential
Tags: throws=CQLParseException,IOException,ParseException,TechnicalException
Notes: Returns a cql root node with the whole cql query in the tree.
@return root node of cql query tree
public
getCqlQuery():String
Sequential
Tags: throws=CQLParseException,IOException,ParseException,TechnicalException
Notes: {@inheritDoc}
public
getCqlString():String
Sequential
Tags: throws=ParseException,TechnicalException
Notes: Get the cql query as string.
@return cql query string
private
isQueryValid():boolean
Sequential
Notes: Checks if a set of criteria can be transformed into a cql query. If a query has more than one criteria, the following criteria must have a logical operator, otherwise no valid cql query can be created.
@return true if query is valid, false if not
public
MetadataSearchQuery(
   ArrayList contentTypes):
Sequential
Tags: throws=TechnicalException
Notes: Creates a query with a list of content types.
public
MetadataSearchQuery(
   ArrayList contentTypes,
   ArrayList criteria):
Sequential
Tags: throws=TechnicalException
Notes: Creates a query with a list of content types and a list of search criteria.