Package org.xooof.xooofoscope.struct

Examples of org.xooof.xooofoscope.struct.SInstrumentArrayList


    
    InstrumentHome bc = (InstrumentHome) xdCtx.getBusinessClass("Instrument");
    SObjRef objRef = new SObjRef();
    objRef.setObjId(getId());
    objRef.setObjClass(SObjRef.class.getName());
    SInstrumentArrayList  instrumentList = bc.queryByTelescope(xdCtx, objRef);
   
    rply.setInstrumentsList(instrumentList);
   
    return rply;
   
View Full Code Here


  public SInstrumentArrayList fetchByTelescopeId(Integer telescopeId) throws DAOException {

    if (telescopeId == null) {
      throw new InstrumentDAOException("telescopeId cannot be null");
    }
    SInstrumentArrayList instrumentList = new SInstrumentArrayList();
    SInstrument instrument = null;
    PreparedStatement statement = null;
    ResultSet result;   
    Connection connection = DAOHelper.getDBConnection();   
    try {   
      try
      {
      statement = connection.prepareStatement(FETCHBYTELESCOPE_QRY);
      statement.setInt(1, telescopeId.intValue());
      result = statement.executeQuery();
      while(result.next())
      {
        instrument = new SInstrument();
        instrument.setObjId(result.getString("id"));
        instrument.setObjClass(SInstrument.class.getName());       
        instrument.setTelescopeId(result.getString("telescope_id"));
        instrument.setName(result.getString("name"));
        instrument.setDescr(result.getString("description"));
        instrumentList.add(instrument);
      }
      }
      catch(SQLException exc)
      {
        throw new InstrumentDAOException(exc.getMessage());
View Full Code Here

   
  }

  public SInstrumentArrayList fetchAll() throws DAOException {

    SInstrumentArrayList instrumentList = new SInstrumentArrayList();
    SInstrument instrument = null;
    PreparedStatement statement = null;
    ResultSet result;  
    Connection connection = DAOHelper.getDBConnection();   
    try {  
      try
      {
      statement = connection.prepareStatement(FETCHALL_QRY);
      result = statement.executeQuery();
      while(result.next())
      {
        instrument = new SInstrument();
        instrument.setObjId(result.getString("id"));
        instrument.setObjClass(SInstrument.class.getName());       
        instrument.setTelescopeId(result.getString("telescope_id"));
        instrument.setName(result.getString("name"));
        instrument.setDescr(result.getString("description"));
        instrumentList.add(instrument);
      }
      }
      catch(SQLException exc)
      {
        throw new InstrumentDAOException(exc.getMessage());
View Full Code Here

TOP

Related Classes of org.xooof.xooofoscope.struct.SInstrumentArrayList

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.