public String toString() { return super.toString() + " ref: " + m_id; } }
/** * Access the resource id. * * @return The resource id. */ public String getResource() { return getId(); }
/** * {@inheritDoc} */ @Override public String getMessage() { return "user=" + m_user + " lock=" + m_lock + " resource=" + getResource(); }
/** * {@inheritDoc} */ @Override public boolean saveSite(final Site site) { try { this.siteService.save(site); } catch (final IdUnusedException e) { e.printStackTrace(); return false; } catch (final PermissionException e) { e.printStackTrace(); return false; } return true; }
protected boolean existsDirectory(String path) { try { contentHostingService.getCollection(path); } catch (IdUnusedException e) { return false; } catch (TypeException e) { log.error(e.getMessage(), e); } catch (PermissionException e) { log.error("ResourcesHandler.existsDirectory: {}", e.toString()); } return true; }
public CitationCollection getCollection(String collectionId) throws IdUnusedException { CitationCollection edit = m_storage.getCollection(collectionId); if (edit == null) { throw new IdUnusedException(collectionId); } return edit; }
/** * {@inheritDoc} */ @Override public Site addSite(final String id, final String type) { Site site = null; try { site = this.siteService.addSite(id, type); } catch (final IdInvalidException e) { e.printStackTrace(); } catch (final IdUsedException e) { e.printStackTrace(); } catch (final PermissionException e) { e.printStackTrace(); } return site; }
/** * {@inheritDoc} */ @Override public Site getSite(final String siteId) { try { return this.siteService.getSite(siteId); } catch (final IdUnusedException e) { e.printStackTrace(); return null; } }
public void setCorrelation(double correlation) { if (a.equals(b)) { if (Math.abs(correlation - 1D) > EPSILON) { throw new InconsistentException(...); } this.correlation = 1D; } else { this.correlation= correlation; } }
try{ av = UserHelper.importUsers(data, admin); System.out.print("test2"); } catch (ImportException ie) { System.out.print("testE"); returnMessageValue = ie.getMessage(); } catch (Exception e) { System.out.print("testE2"); } catch (Throwable t) { // Here you'll catch *anything* else System.out.print("testTE"); }
public String getMessage() { return getId(); }
protected boolean existsDirectory(String path) { try { contentHostingService.getCollection(path); } catch (IdUnusedException e) { return false; } catch (TypeException e) { log.error(e.getMessage(), e); } catch (PermissionException e) { log.error("ResourcesHandler.existsDirectory: {}", e.toString()); } return true; }
/** * {@inheritDoc} */ @Override public String getMessage() { return "user=" + m_user + " lock=" + m_lock + " resource=" + getResource(); }
/** * @inheritDoc */ public Digest getDigest(String id) throws IdUnusedException { Digest digest = findDigest(id); if (digest == null) throw new IdUnusedException(id); return digest; }
private Site getSite(String siteId) { Site site = null; try { site = SiteService.getSite(siteId); } catch (IdUnusedException e) { // TODO Auto-generated catch block e.printStackTrace(); } return site; }
public String toString() { return super.toString() + ((m_ref != null) ? (" : " + m_ref) : ""); } }
/** * Access the resource id. * * @return The resource id. */ public String getResource() { return getId(); }
public String getMessage() { return getId(); }
public String toString() { return super.toString() + " ref: " + m_id; } }
public String toString() { return super.toString() + ((m_ref != null) ? (" : " + m_ref) : ""); } }