Examples of ModelSet


Examples of org.ontoware.rdf2go.model.ModelSet

        final String expectedString = "null - http://nonexistent.com/abox#Document1823812 - http://www.w3.org/1999/02/22-rdf-syntax-ns#type - http://nonexistent.com/tbox#Document";
        final Object input = JSONUtils.fromString(inputstring);

        final RDF2GoTripleCallback callback = new RDF2GoTripleCallback();

        final ModelSet model = (ModelSet) JsonLdProcessor.toRDF(input, callback);

        // contains only one statement (type)
        final ClosableIterator<Statement> statements = model.iterator();
        final Statement stmt = statements.next();
        assertEquals(expectedString, stmt.getContext() + " - " + stmt.toString());
        assertFalse("Deserialized RDF contains more triples than expected", statements.hasNext());
    }
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.