dragon.ir.query
Interface IRQuery

All Known Subinterfaces:
Predicate
All Known Implementing Classes:
AbstractIRQuery, AbstractPredicate

public interface IRQuery

Interface of IR Query

Copyright: Copyright (c) 2005

Company: IST, Drexel University

Version:
1.0
Author:
Davis Zhou

Method Summary
 IRQuery getChild(int index)
           
 int getChildNum()
           
 Operator getOperator()
           
 int getQueryKey()
           
 double getSelectivity()
           
 boolean isCompoundQuery()
          If the current query denotes a simple predicate, this method returns false, otherwise true.
 boolean isPredicate()
          A predicate always begins with a ltter T (term predicate), R(relation predicate), or M(modifier predicate)
 boolean isRelBoolQuery()
           
 boolean isRelSimpleQuery()
           
 boolean parse(java.lang.String query)
           
 void setQueryKey(int key)
           
 java.lang.String toString()
           
 

Method Detail

getQueryKey

public int getQueryKey()
Returns:
the unique id of the query

setQueryKey

public void setQueryKey(int key)

isPredicate

public boolean isPredicate()
A predicate always begins with a ltter T (term predicate), R(relation predicate), or M(modifier predicate)

Returns:
true if the the current query denotes a simple predicate, otherwise false.

isCompoundQuery

public boolean isCompoundQuery()
If the current query denotes a simple predicate, this method returns false, otherwise true.

Returns:
false if the the current query denotes a simple predicate, otherwise true.

isRelSimpleQuery

public boolean isRelSimpleQuery()

isRelBoolQuery

public boolean isRelBoolQuery()

getChild

public IRQuery getChild(int index)

getChildNum

public int getChildNum()

getSelectivity

public double getSelectivity()

getOperator

public Operator getOperator()

toString

public java.lang.String toString()
Overrides:
toString in class java.lang.Object

parse

public boolean parse(java.lang.String query)
Parameters:
query - the query string
Returns:
a structured query