no.priv.garshol.duke.utils
Class NTriplesParser

java.lang.Object
  extended by no.priv.garshol.duke.utils.NTriplesParser

public class NTriplesParser
extends Object

A basic NTriples parser used by NTriplesDataSource.


Constructor Summary
NTriplesParser(StatementHandler handler)
          Alternate entry point to the parser for when the driving loop is outside the parser.
 
Method Summary
static void parse(Reader src, StatementHandler handler)
          Reads the NTriples file from the reader, pushing statements into the handler.
 void parseLine(String line)
          Push a line into the parser.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

NTriplesParser

public NTriplesParser(StatementHandler handler)
Alternate entry point to the parser for when the driving loop is outside the parser. Statements get passed to the handler.

Method Detail

parse

public static void parse(Reader src,
                         StatementHandler handler)
                  throws IOException
Reads the NTriples file from the reader, pushing statements into the handler.

Throws:
IOException

parseLine

public void parseLine(String line)
Push a line into the parser. If it contains a statement, that statement will be passed to the handler.



Copyright © 2013. All Rights Reserved.