simpledb.parse
Class QueryData

java.lang.Object
  extended by simpledb.parse.QueryData

public class QueryData
extends java.lang.Object

Data for the SQL select statement.

Author:
Edward Sciore

Constructor Summary
QueryData(java.util.Collection<java.lang.String> fields, java.util.Collection<java.lang.String> tables, Predicate pred)
          Saves the field and table list and predicate.
 
Method Summary
 java.util.Collection<java.lang.String> fields()
          Returns the fields mentioned in the select clause.
 Predicate pred()
          Returns the predicate that describes which records should be in the output table.
 java.util.Collection<java.lang.String> tables()
          Returns the tables mentioned in the from clause.
 java.lang.String toString()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

QueryData

public QueryData(java.util.Collection<java.lang.String> fields,
                 java.util.Collection<java.lang.String> tables,
                 Predicate pred)
Saves the field and table list and predicate.

Method Detail

fields

public java.util.Collection<java.lang.String> fields()
Returns the fields mentioned in the select clause.

Returns:
a collection of field names

tables

public java.util.Collection<java.lang.String> tables()
Returns the tables mentioned in the from clause.

Returns:
a collection of table names

pred

public Predicate pred()
Returns the predicate that describes which records should be in the output table.

Returns:
the query predicate

toString

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