Package org.apache.stanbol.entityhub.servicesapi

Examples of org.apache.stanbol.entityhub.servicesapi.Entityhub.find()


            return executeLDPathQuery(entityhub,query, ((LDPathSelect)query).getLDPathSelect(),
                acceptedMediaType, headers);
        } else { //use the default query execution
            QueryResultList<Representation> result;
            try {
                result = entityhub.find(query);
            } catch (EntityhubException e) {
                String message = String.format("Exception while performing the " +
                    "FieldQuery on the EntityHub (message: %s)", e.getMessage());
                log.error(message, e);
                return Response.status(Status.INTERNAL_SERVER_ERROR)
View Full Code Here


        if(offset != null && offset.intValue() > 0){
            query.setOffset(offset.intValue());
        }
        QueryResultList<Representation> results;
        try {
            results = entityhub.find(query);
        } catch (EntityhubException e) {
            throw new EntitySearcherException("Exception while searchign for "+
                search+'@'+Arrays.toString(languages)+"in the Entityhub", e);
        }
        if(!results.isEmpty()){
View Full Code Here

            return executeLDPathQuery(entityhub,query, ((LDPathSelect)query).getLDPathSelect(),
                acceptedMediaType, headers);
        } else { //use the default query execution
            QueryResultList<Representation> result;
            try {
                result = entityhub.find(query);
            } catch (EntityhubException e) {
                String message = String.format("Exception while performing the " +
                    "FieldQuery on the EntityHub (message: %s)", e.getMessage());
                log.error(message, e);
                return Response.status(Status.INTERNAL_SERVER_ERROR)
View Full Code Here

            return executeLDPathQuery(entityhub,query, ((LDPathSelect)query).getLDPathSelect(),
                acceptedMediaType, headers);
        } else { //use the default query execution
            QueryResultList<Representation> result;
            try {
                result = entityhub.find(query);
            } catch (EntityhubException e) {
                String message = String.format("Exception while performing the " +
                    "FieldQuery on the EntityHub (message: %s)", e.getMessage());
                log.error(message, e);
                return Response.status(Status.INTERNAL_SERVER_ERROR)
View Full Code Here

        }
        FieldQuery query = EntitySearcherUtils.createFieldQuery(entityhub.getQueryFactory(),
            field, includeFields, search, languages);
        QueryResultList<Representation> results;
        try {
            results = entityhub.find(query);
        } catch (EntityhubException e) {
            throw new IllegalStateException("Exception while searchign for "+
                search+'@'+Arrays.toString(languages)+"in the Entityhub", e);
        }
        return results.results();
View Full Code Here

        } else if(this.limit != null){
            query.setLimit(this.limit);
        }
        QueryResultList<Representation> results;
        try {
            results = entityhub.find(query);
        } catch (EntityhubException e) {
            throw new EntitySearcherException("Exception while searchign for "+
                search+'@'+Arrays.toString(languages)+"in the Entityhub", e);
        }
        Collection<Entity> entities = new ArrayList<Entity>(results.size());
View Full Code Here

        }
        FieldQuery query = EntitySearcherUtils.createFieldQuery(entityhub.getQueryFactory(),
            field, includeFields, search, languages);
        QueryResultList<Representation> results;
        try {
            results = entityhub.find(query);
        } catch (EntityhubException e) {
            throw new IllegalStateException("Exception while searchign for "+
                search+'@'+Arrays.toString(languages)+"in the Entityhub", e);
        }
        return results.results();
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. 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.