Package edu.ubb.warp.model

Examples of edu.ubb.warp.model.ResourceType


      list.addContainerProperty("Type ID", String.class, null);
      list.addContainerProperty("Type Name", String.class, null);
      // list.setVisibleColumns(new Object[] { "Type Name" });
      for (int i = 0; i < resArray.size(); i++) {

        ResourceType resType = resArray.get(i);
        list.addItem(
            new Object[] {
                Integer.toString(resType.getResourceTypeID()),
                resType.getResourceTypeName() }, i);
      }

    } catch (DAOException e) {
      e.printStackTrace();
      me.getApplication().getMainWindow()
View Full Code Here


public class ResourceTypeJdbcDAO implements ResourceTypeDAO {

  public ResourceType getResourceTypeByResourceTypeID(int resourceTypeID)
      throws DAOException, ResourceTypeNotFoundException {
    ResourceType resourceType = new ResourceType();
    try {
      String command = "SELECT * FROM `ResourceTypes` WHERE `ResourceTypeID` = ?";
      PreparedStatement statement = JdbcConnection.getConnection()
          .prepareStatement(command);
      statement.setInt(1, resourceTypeID);
View Full Code Here

    }
  }

  private ResourceType getResourceTypeFromResult(ResultSet result)
      throws SQLException {
    ResourceType resourceType = new ResourceType();
    resourceType.setResourceTypeID(result.getInt("ResourceTypeID"));
    resourceType.setResourceTypeName(result.getString("ResourceTypeName"));
    return resourceType;
  }
View Full Code Here

    return resourceTypes;
  }

  public ResourceType getResourceTypeByResourceTypeName(String resourceTypeName)
      throws ResourceTypeNotFoundException, DAOException {
    ResourceType resourceType = new ResourceType();
    try {
      String command = "SELECT * FROM `ResourceTypes` WHERE `ResourceTypeName` = ?";
      PreparedStatement statement = JdbcConnection.getConnection()
          .prepareStatement(command);
      statement.setString(1, resourceTypeName);
View Full Code Here

TOP

Related Classes of edu.ubb.warp.model.ResourceType

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.