Package org.openqreg.bean

Examples of org.openqreg.bean.FileKey


    Long fileId = fetch.getValueAsLong("fileId");

    FileBean fileToGet = null;
    try {
      fileToGet = (FileBean) FileFinder.findByPrimaryKey(new FileKey(
          fileId));
    } catch (SQLException e) {
      log.log(Level.ERROR, "giveService() error finding file:", e);

    }
View Full Code Here


* @return The primaryKey
*
*/
@JsonIgnore
public PrimaryKey getPrimaryKey() {
return new FileKey(getId());
}
View Full Code Here

*/
public static Object findByPrimaryKey(Connection con, PrimaryKey key) throws SQLException {
PreparedStatement pStmt = null;
ResultSet rs = null;
FileBean valueObject = null;
FileKey primaryKey = (FileKey) key;
try{
pStmt = con.prepareStatement(FileBeanBase.SELECT_STATEMENT);
pStmt.setObject(1, primaryKey.getId());
rs = pStmt.executeQuery();
while (rs.next()){
valueObject = populate(rs);
valueObject.afterPopulate(con);
}
View Full Code Here

    Connection con = null;
    try {
      con = DbHandler.getConnection();
      con.setAutoCommit(false);
      FileBean fileBean = (FileBean) FileFinder.findByPrimaryKey(con,
          new FileKey(fileId));

      // service groups
      Collection<FileshareuserBean> col = FileshareuserFinder
          .findByFileid(con, fileBean.getId());
      // loop exsisting FileshareuserBean update or remove based on
View Full Code Here

TOP

Related Classes of org.openqreg.bean.FileKey

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.