Package edu.spbstu.hoteldb.sql

Examples of edu.spbstu.hoteldb.sql.SearchRoomQuery


    connect = connection;
  }

  @Override
  public void handle(ActionEvent arg0) {
    SQLQuery query = new SearchRoomQuery(connect, results);
    LinkedList<Object> args = new LinkedList<Object>();
    Integer pc = Integer.MAX_VALUE;
    Integer cost = Integer.MAX_VALUE;
    try {
      pc = Integer.parseInt(tfpcount.getText());
    } catch (NumberFormatException e) {
      // ignore
    }
    try {
      cost = Integer.parseInt(tfcost.getText());
    } catch (NumberFormatException e) {
      // ignore
    }
    args.addLast(pc);
    args.addLast(cost);
    args.addLast(new Boolean(chckbxdesc.isSelected()));
    args.addLast(chbbar.getValue());

    try {
      query.prepareQuery(args);
      query.doQuery();
      query.close();
    } catch (SQLException e) {
      results.appendText(e.getMessage() + '\n');
      e.printStackTrace();
    }
  }
View Full Code Here

TOP

Related Classes of edu.spbstu.hoteldb.sql.SearchRoomQuery

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.