Examples of Triple


Examples of com.hp.hpl.jena.graph.Triple

        assertEquals(0,c.compare(base, new Triple(A,B,C)));
    }

    @Test
    public void testABA() {
        assertTrue(c.compare(base, new Triple(A,B,A))==0);
    }
View Full Code Here

Examples of com.hp.hpl.jena.graph.Triple

        assertTrue(c.compare(base, new Triple(A,B,A))==0);
    }

    @Test
    public void testABB() {
        assertTrue(c.compare(base, new Triple(A,B,B))==0);
    }
View Full Code Here

Examples of com.hp.hpl.jena.graph.Triple

        assertTrue(c.compare(base, new Triple(A,B,B))==0);
    }

    @Test
    public void testABBreversed() {
        assertTrue(c.compare(new Triple(A,B,B),base)==0);
    }
View Full Code Here

Examples of com.hp.hpl.jena.graph.Triple

        assertTrue(c.compare(new Triple(A,B,B),base)==0);
    }

    @Test
    public void testCBC() {
        assertTrue(c.compare(base,new Triple(C,B,C))<0);
    }
View Full Code Here

Examples of com.hp.hpl.jena.graph.Triple

        assertTrue(c.compare(base,new Triple(C,B,C))<0);
    }

    @Test
    public void testCCB() {
        assertTrue(c.compare(base,new Triple(C,C,B))<0);
    }
View Full Code Here

Examples of com.hp.hpl.jena.graph.Triple

        assertTrue(c.compare(base,new Triple(C,C,B))<0);
    }

    @Test
    public void testAAC() {
        assertTrue(c.compare(base,new Triple(A,A,C))==0);
    }
View Full Code Here

Examples of com.hp.hpl.jena.graph.Triple

        assertTrue(c.compare(base,new Triple(A,A,C))==0);
    }

    @Test
    public void testACC() {
        assertTrue(c.compare(base,new Triple(A,C,C))==0);
    }
View Full Code Here

Examples of com.hp.hpl.jena.graph.Triple

    public void canRoundtripALinkTriple() throws IOException {
        Node s=Node.createURI("http://example.com/A1");
        Node p=Node.createURI("http://example.com/B2");
        Node o=Node.createURI("http://example.com/C3");
       
        Triple source=new Triple(s,p,o);
        WritableTriple wt1=new WritableTriple(source);
        WritableTriple wt2=new WritableTriple(null);
       
        roundtrip(wt1,wt2);
        Triple destination=wt2.getTriple();
        assertEquals(source,destination);
    }
View Full Code Here

Examples of com.hp.hpl.jena.graph.Triple

        assertEquals(source,destination);
    }
   
    @Test
    public void twoTriplesWithTheSamePOAreNotEqual() {
        WritableTriple croatianKey=new WritableTriple(new Triple(
                Node_URI.createURI("http://rdf.basekb.com/ns/m.0tc7")
                ,Node_URI.createURI("http://rdf.basekb.com/ns/type.object.key")
                ,Node.createLiteral("/wikipedia/hr_title/Arnold_Schwarzenegger")
        ));
       
        WritableTriple polishKey=new WritableTriple(new Triple(
                Node_URI.createURI("http://rdf.basekb.com/ns/m.0tc7")
                ,Node_URI.createURI("http://rdf.basekb.com/ns/type.object.key")
                ,Node.createLiteral("/wikipedia/pl/Arnold_Schwarzenegger")
        ));
       
View Full Code Here

Examples of com.hp.hpl.jena.graph.Triple

public class STripleOutputFormat extends TripleOutputFormat<Node,NodePair> {

    @Override
    protected Triple makeTriple(Node key, NodePair value) {
        // TODO Auto-generated method stub
        return new Triple(key,value.getOne(),value.getTwo());
    }
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.