Package org.jrdf.parser

Examples of org.jrdf.parser.RdfReader


        return application.getGraphsDir();
    }

    private void refreshGraphsModel() {
        final File file = new File(handler.getDir(), graphsFile);
        final Graph modelsGraph = new RdfReader().parseNTriples(file);
        final Models model = new ModelsImpl(modelsGraph);
        this.resources = model.getResources();
    }
View Full Code Here


        this(Mode.NT);
    }
   
    public RdfTripleImporter(Mode mode) {
        super(true);
        rdfReader = new RdfReader();
        this.mode = mode;
    }
View Full Code Here

    public long getGraphId(String name) {
        return models.getId(name);
    }

    public void refresh() {
        modelsGraph = new RdfReader().parseNTriples(file);
        models = new ModelsImpl(modelsGraph);
    }
View Full Code Here

    }

    private void parse(URL url) throws Exception {
        graph.clear();
        final String fileName = url.toExternalForm();
        rdfReader = new RdfReader(graph, mapFactory);
        if (fileName.endsWith(".nt")) {
            rdfReader.parseNTriples(url.openStream());
        } else if (fileName.endsWith(".n3")) {
            rdfReader.parseN3(url.openStream());
        } else if (fileName.endsWith(".rdf")) {
View Full Code Here

TOP

Related Classes of org.jrdf.parser.RdfReader

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.