net.rootdev.javardfa.jena
Class JenaStatementSink

java.lang.Object
  extended by net.rootdev.javardfa.jena.JenaStatementSink
All Implemented Interfaces:
StatementSink

public class JenaStatementSink
extends Object
implements StatementSink

Author:
Damian Steer

Constructor Summary
JenaStatementSink(Model model)
           
 
Method Summary
 void addLiteral(String subject, String predicate, String lex, String lang, String datatype)
          Add statement with a literal object.
 void addObject(String subject, String predicate, String object)
          Add statement with non-literal object.
 void addPrefix(String prefix, String uri)
          Add a prefix mapping.
 void end()
          Complete parsing
 void setBase(String base)
           
 void start()
          Begin parsing
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

JenaStatementSink

public JenaStatementSink(Model model)
Method Detail

start

public void start()
Description copied from interface: StatementSink
Begin parsing

Specified by:
start in interface StatementSink

end

public void end()
Description copied from interface: StatementSink
Complete parsing

Specified by:
end in interface StatementSink

addObject

public void addObject(String subject,
                      String predicate,
                      String object)
Description copied from interface: StatementSink
Add statement with non-literal object. Blank nodes begin with _:, variables with ?, otherwise IRI

Specified by:
addObject in interface StatementSink
Parameters:
subject - Subject of triple
predicate - Predicate
object - Object

addLiteral

public void addLiteral(String subject,
                       String predicate,
                       String lex,
                       String lang,
                       String datatype)
Description copied from interface: StatementSink
Add statement with a literal object. As above, blank nodes begin with _:, variables with ?, otherwise IRI

Specified by:
addLiteral in interface StatementSink
Parameters:
subject - Subject of triple
predicate - Predicate
lex - Lexical form
lang - Language (may be null)
datatype - Datatype IRI (may be null)

addPrefix

public void addPrefix(String prefix,
                      String uri)
Description copied from interface: StatementSink
Add a prefix mapping.

Specified by:
addPrefix in interface StatementSink

setBase

public void setBase(String base)
Specified by:
setBase in interface StatementSink


Copyright © 2009-2012. All Rights Reserved.