All Packages  Class Hierarchy  This Package  Previous  Next  Index

Class tc.database.RemoveTimeSlicesQuery

java.lang.Object
   |
   +----tc.database.DatabaseQuery
           |
           +----tc.database.RemoveTimeSlicesQuery

public class RemoveTimeSlicesQuery
extends DatabaseQuery
RemoveTimeSlicesQuery implements the abstract methods in DatabaseQuery so that calling them causes the removing of the parameter TimeSlices from the database.

Version:
0.30, 1998/04/01
Author:
FRED development team, Antti Viljamaa

Constructor Index

 o RemoveTimeSlicesQuery(Vector)
Creates a new query.

Method Index

 o calculate(QueryDataSet)
Finalizes the query by removing the time slices from the dataset.
 o doValidationCheck()
Checks that the database manager has fetched proper markers.
 o getSQLClause()
Returns the SQL query for creating the needed dataset.
 o isWriteQuery()
Returns true.
 o removeOneTimeSliceRowFromDataSet(QueryDataSet, int, long, long)
Removes the specified row from a data set representing the contents of the 'WorkDone' table.

Constructors

 o RemoveTimeSlicesQuery
 public RemoveTimeSlicesQuery(Vector timeSlices)
Creates a new query. The removed time slices are given as a parameter.

Methods

 o calculate
 public void calculate(QueryDataSet dataset) throws DataSetException, ValidationException
Finalizes the query by removing the time slices from the dataset.

Overrides:
calculate in class DatabaseQuery
 o doValidationCheck
 public void doValidationCheck() throws ValidationException
Checks that the database manager has fetched proper markers.

Overrides:
doValidationCheck in class DatabaseQuery
 o getSQLClause
 public String getSQLClause()
Returns the SQL query for creating the needed dataset.

Returns:
String A string representing the query.
Overrides:
getSQLClause in class DatabaseQuery
 o isWriteQuery
 public boolean isWriteQuery()
Returns true.

Returns:
true
Overrides:
isWriteQuery in class DatabaseQuery
 o removeOneTimeSliceRowFromDataSet
 private void removeOneTimeSliceRowFromDataSet(QueryDataSet dataset,
                                               int markerID,
                                               long startTime,
                                               long endTime) throws DataSetException, InvalidMarkerException
Removes the specified row from a data set representing the contents of the 'WorkDone' table.

Parameters:
markerID - The marker id that specifies the row that is removed.
startTime - The start time (milliseconds since 01.01.1970) of the removed time slice. The last three digits are truncated from the given start time.
endTime - The end time (milliseconds since 01.01.1970) of the removed time slice. The last three digits are truncated from the given end time.

All Packages  Class Hierarchy  This Package  Previous  Next  Index