Package de.fzi.herakles.commons

Examples of de.fzi.herakles.commons.Query


   * get the index of cache key
   * @param key the cache key(query)
   * @return the index of the query result in the cahe, if cache miss return <code>null</code>
   */
  private Integer getIndex(CacheKey key){
    Query query = (Query) key;
   
    for(Object o: indexMap.keySet()){
      Query q = (Query) o;
      if(query.equals(q)){
        return (Integer)indexMap.get(o);
      }
    }
    return null;
View Full Code Here


  /* (non-Javadoc)
   * @see de.fzi.circalc.util.caching.CacheDataSource#fetch(de.fzi.circalc.util.caching.CacheKey)
   */
  @Override
  public Object fetch(CacheKey key) throws Exception {
    Query query = (Query) key;
//    Result result = new SynchronousResult( manager );
    Result result = new Result();
    executionStrategy.execute( query, result );
   
    return result;
View Full Code Here

   * get the index of cache key
   * @param key the cache key(query)
   * @return the index of the query result in the cache, if cache miss return <code>null</code>
   */
  private Integer getIndex(CacheKey key){
    Query query = (Query) key;
   
    for(Object o: indexMap.keySet()){
      Query q = (Query) o;
      if(query.equals(q)){
        return (Integer)indexMap.get(o);
      }
    }
    return null;
View Full Code Here

    OWLClassExpression des = (OWLClassExpression) this.query.getParams()[0];
    OWLClassExpression negDes = des.getComplementNNF();
   
    Class<?>[] paramTypes = { OWLClassExpression.class, boolean.class };
    Object[] params = { negDes, false };
    Query negQuery;
        try {
            negQuery = QueryFactory.getQuery( "getIndividuals", paramTypes, params );
            int reasonerNumber = 0;
            if(positiveSoundReasoner != null){
                reasonerNumber++;
View Full Code Here

  @Deprecated
  public Object execute( String taskName, Class<?>[] paramTypes, Object[] params )
      throws HeraklesException {

        Result result = null;
    Query query;
        try {
            query = QueryFactory.getQuery( taskName, paramTypes, params );
            this.execute( query, result );
        } catch( IllegalArgumentException e ) {
            // TODO Auto-generated catch block
View Full Code Here

    OWLClassExpression negDes = des.getComplementNNF();
   
    Class<?>[] paramTypes = { OWLClassExpression.class };
    Object[] params = { negDes };
        try {
            Query negQuery = QueryFactory.getQuery( "getIndividuals", paramTypes, params );
        } catch( IllegalArgumentException e ) {
            // TODO Auto-generated catch block
            e.printStackTrace();
        } catch( ClassCastException e ) {
            // TODO Auto-generated catch block
View Full Code Here

    OWLClassExpression negDes = des.getComplementNNF();
   
    Class<?>[] paramTypes = { OWLClassExpression.class };
    Object[] params = { negDes };
    try {
            Query negQuery = QueryFactory.getQuery( "getIndividuals", paramTypes, params );
        } catch( IllegalArgumentException e ) {
            // TODO Auto-generated catch block
            e.printStackTrace();
        } catch( ClassCastException e ) {
            // TODO Auto-generated catch block
View Full Code Here

      // FIXME: This method does nothing !!!
     
    Class<?>[] paramTypes = {};
    Object[] params = {};
   
    Query query;
        try {
            query = QueryFactory.getQuery( "flush", paramTypes, params );
            if(logger.isInfoEnabled()){
              logger.info( "Executing " + query.getTask() + " ..." );
            }
        } catch( IllegalArgumentException e ) {
            // TODO Auto-generated catch block
            e.printStackTrace();
        } catch( ClassCastException e ) {
View Full Code Here

  @Deprecated
  public Object execute( String taskName, Class<?>[] paramTypes, Object[] params )
      throws HeraklesException {

        Result result = null;
    Query query;
        try {
            query = QueryFactory.getQuery( taskName, paramTypes, params );
            this.execute( query, result );
        } catch( IllegalArgumentException e ) {
            // TODO Auto-generated catch block
View Full Code Here

  @Deprecated
  public Object execute( String taskName, Class<?>[] paramTypes,
      Object[] params ) throws HeraklesException {

        Result result = null;
    Query query;
        try {
            query = QueryFactory.getQuery( taskName, paramTypes, params );
            this.execute( query, result );
        } catch( IllegalArgumentException e ) {
            // TODO Auto-generated catch block
View Full Code Here

TOP

Related Classes of de.fzi.herakles.commons.Query

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.