private Site getSite(String siteId) { Site site = referencedSiteManager.getSite(siteId); if (site == null) { log.error("Site {} not found (no referenced site with that ID is present within the Entityhub", siteId); throw new WebApplicationException(Response.Status.NOT_FOUND); } if(site instanceof ManagedSite){ log.debug(" ... init ManagedSite"); } return site; }
private Site getSite(String siteId) throws WebApplicationException { Site site = _siteManager.getSite(siteId); if (site == null) { String message = String.format("ReferencedSite '%s' not active!",siteId); log.error(message); throw new WebApplicationException( Response.status(Status.NOT_FOUND).entity(message).build()); } return site; } /**
/** * Retrieves the configured {@link Site} which holds the NER properties. * * @return * @throws EngineException */ private Site getReferencedSite() throws EngineException { Site site = null; if (referencedSiteID != null) { // lookup the referenced site site = siteManager.getSite(referencedSiteID); // ensure that it is present if (site == null) { String msg = String .format("Unable to enhance because Referenced Site %s is currently not active!", referencedSiteID); throw new EngineException(msg); } } return site; } }
public void computeEnhancements(ContentItem ci) throws EngineException { final Site site; if (referencedSiteID != null) { // lookup the referenced site site = siteManager.getSite(referencedSiteID);
Site site = siteManager.getSite(savedEntity.getSite());
return null; Site site = siteManager.getSite(remoteEntity.getSite()); if(site == null){ log.warn("Unable to import Entity {} because the ReferencedSite {} is currently not active -> return null",
return null; Site site = siteManager.getSite(remoteEntity.getSite()); if(site == null){ log.warn("Unable to import Entity {} because the ReferencedSite {} is currently not active -> return null",