simpledb.parse
Class ModifyData

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

public class ModifyData
extends Object

Data for the SQL update statement.

Author:
Edward Sciore

Constructor Summary
ModifyData(String tblname, String fldname, Expression newval, Predicate pred)
          Saves the table name, the modified field and its new value, and the predicate.
 
Method Summary
 Expression newValue()
          Returns an expression.
 Predicate pred()
          Returns the predicate that describes which records should be modified.
 String tableName()
          Returns the name of the affected table.
 String targetField()
          Returns the field whose values will be modified
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ModifyData

public ModifyData(String tblname,
                  String fldname,
                  Expression newval,
                  Predicate pred)
Saves the table name, the modified field and its new value, and the predicate.

Method Detail

tableName

public String tableName()
Returns the name of the affected table.

Returns:
the name of the affected table

targetField

public String targetField()
Returns the field whose values will be modified

Returns:
the name of the target field

newValue

public Expression newValue()
Returns an expression. Evaluating this expression for a record produces the value that will be stored in the record's target field.

Returns:
the target expression

pred

public Predicate pred()
Returns the predicate that describes which records should be modified.

Returns:
the modification predicate


Copyright © 2011. All Rights Reserved.