org.opensha.refFaultParamDb.dao.db
Class TimeInstanceDB_DAO

java.lang.Object
  extended by org.opensha.refFaultParamDb.dao.db.TimeInstanceDB_DAO

public class TimeInstanceDB_DAO
extends Object

Title: TimeInstanceDB_DAO.java

Description: Time Instance DB DAO. It adds the time instance to the database. It checks whether time is exact time or an estimate and handles appropriately

Copyright: Copyright (c) 2002

Company:

Version:
1.0
Author:
not attributable

Constructor Summary
TimeInstanceDB_DAO(DB_AccessAPI dbAccessAPI)
          Constructor.
 
Method Summary
 int addTimeInstance(TimeAPI timeInstance)
          Add time instance to the database
 TimeAPI getTimeInstance(int timeInstanceId)
          Get time instance based on time instances id
 boolean removeTimeInstance(int timeInstanceId)
          remove the time instance from the table
 void setDB_Connection(DB_AccessAPI dbAccessAPI)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

TimeInstanceDB_DAO

public TimeInstanceDB_DAO(DB_AccessAPI dbAccessAPI)
Constructor.

Parameters:
dbConnection -
Method Detail

setDB_Connection

public void setDB_Connection(DB_AccessAPI dbAccessAPI)

addTimeInstance

public int addTimeInstance(TimeAPI timeInstance)
                    throws InsertException
Add time instance to the database

Parameters:
estimateInstance -
Throws:
InsertException

getTimeInstance

public TimeAPI getTimeInstance(int timeInstanceId)
                        throws QueryException
Get time instance based on time instances id

Parameters:
timeInstanceId -
Returns:
Throws:
QueryException

removeTimeInstance

public boolean removeTimeInstance(int timeInstanceId)
                           throws UpdateException
remove the time instance from the table

Parameters:
timeInstanceId -
Returns:
Throws:
UpdateException