Package com.clarkparsia.pellet.sparqldl.model

Examples of com.clarkparsia.pellet.sparqldl.model.Query


  @Test
  public void test4() {
    classes( A, B );
    individuals( a, b );

    Query q = ask( NotKnownAtom( TypeAtom( x, B ) ) );

    testQuery( q, true );
  }
View Full Code Here


    classes( A, B );
    individuals( a, b );

    kb.addType( b, B );

    Query q = ask( NotKnownAtom( TypeAtom( x, B ) ) );

    testQuery( q, false );
  }
View Full Code Here

    classes( A, B );
    individuals( a, b, c );

    kb.addType( b, B );

    Query q = query( select( x ),
             where( TypeAtom( x, TermFactory.TOP ),
                NotKnownAtom( TypeAtom( x, B ) ) ) );

    testQuery( q, new ATermAppl[][] { { a }, { c } } );
  }
View Full Code Here

    kb.addType( a, A );
    kb.addType( b, A );
    kb.addType( b, B );

    Query q = query( select( x ),
             where( TypeAtom( x, A ),
                NotKnownAtom( TypeAtom( x, B ) ) ) );

    testQuery( q, new ATermAppl[][] { { a } } );
  }
View Full Code Here

    classes( A, B );
    individuals( a, b, c );

    kb.addType( a, A );

    Query q1 = query( select( x ),
              where( TypeAtom( x, TOP ),
                 NotKnownAtom( TypeAtom( x, A ) ),
                 NotKnownAtom( TypeAtom( x, B ) ) ) );

    testQuery( q1, new ATermAppl[][] { { b }, { c } } );

    Query q2 = query( select( x ),
              where( TypeAtom( x, TOP ),
                 NotKnownAtom( TypeAtom( x, A ),
                          TypeAtom( x, B ) ) ) );

    testQuery( q2, new ATermAppl[][] { { a }, { b }, { c } } );
View Full Code Here

    objectProperties( p, q );
    individuals( a, b, c );

    kb.addPropertyValue( p, a, b );

    Query q1 = query( select( x ),
              where( TypeAtom( x, TOP ),
                 NotKnownAtom( PropertyValueAtom( x, p, y ) ),
                 NotKnownAtom( PropertyValueAtom( x, q, z ) ) ) );

    testQuery( q1, new ATermAppl[][] { { b }, { c } } );

    Query q2 = query( select( x ),
                where( TypeAtom( x, TOP ),
                   NotKnownAtom( PropertyValueAtom( x, p, y ),
                            PropertyValueAtom( x, q, z ) ) ) );

    testQuery( q2, new ATermAppl[][] { { a }, { b }, { c } } );
View Full Code Here

TOP

Related Classes of com.clarkparsia.pellet.sparqldl.model.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.