Package edu.ubb.warp.exception

Examples of edu.ubb.warp.exception.DAOException


      PreparedStatement statement = JdbcConnection.getConnection()
          .prepareStatement(command);
      statement.setInt(1, status.getStatusID());
      statement.executeUpdate();
    } catch (SQLException e) {
      throw new DAOException();
    }
  }
View Full Code Here


      ResultSet result = statement.executeQuery();
      while (result.next()) {
        statuses.add(getStatusFromResult(result));
      }
    } catch (SQLException e) {
      throw new DAOException();
    }
    return statuses;
  }
View Full Code Here

        resource = getResourceFromResult(result);
      } else {
        throw new ResourceNotFoundException();
      }
    } catch (SQLException e) {
      throw new DAOException();
    }
    return resource;
  }
View Full Code Here

        resource = getResourceFromResult(result);
      } else {
        throw new ResourceNotFoundException();
      }
    } catch (SQLException e) {
      throw new DAOException();
    }
    return resource;
  }
View Full Code Here

      PreparedStatement statement = JdbcConnection.getConnection()
          .prepareStatement(command);
      statement.setInt(1, resource.getResourceID());
      statement.executeUpdate();
    } catch (SQLException e) {
      throw new DAOException();
    }
  }
View Full Code Here

        resource = getResourceFromResult(result);
      } else {
        throw new ResourceNotFoundException();
      }
    } catch (SQLException e) {
      throw new DAOException();
    }
    return resource;
  }
View Full Code Here

            throw new ResourceHasActiveProjectException();
          }
        }

      } catch (SQLException e) {
        throw new DAOException();
      }

    }
  }
View Full Code Here

      ResultSet result = statement.executeQuery();
      while (result.next()) {
        resources.add(getResourceFromResult(result));
      }
    } catch (SQLException e) {
      throw new DAOException();
    }
    return resources;
  }
View Full Code Here

          if (result.getInt("c") < 2) {
            con.setAutoCommit(true);
            throw new ProjectNeedsActiveLeaderException();
          }
        } else {
          throw new DAOException();
        }
      }
      String command = "UPDATE `UserTask` SET `Leader` = ? WHERE `ResourceID` = ? AND `ProjectID` = ?";
      PreparedStatement statement = con.prepareStatement(command);
      statement.setBoolean(1, leader);
      statement.setInt(2, resourceID);
      statement.setInt(3, projectID);
      statement.executeUpdate();
      if (!leader) {
        con.setAutoCommit(true);

      }
    } catch (SQLException e) {
      throw new DAOException();
    }
  }
View Full Code Here

      ResultSet result = statement.executeQuery();
      while (result.next()) {
        resources.add(getResourceFromResult(result));
      }
    } catch (SQLException e) {
      throw new DAOException();
    }
    return resources;
  }
View Full Code Here

TOP

Related Classes of edu.ubb.warp.exception.DAOException

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.