blob: 28436fac7bf75f0a8c68790ce12e2c6cef02fdb6 [file] [log] [blame]
<!DOCTYPE HTML>
<html lang="en">
<head>
<!-- Generated by javadoc (17) -->
<title>RDFParser (Apache Jena ARQ)</title>
<meta name="viewport" content="width=device-width, initial-scale=1">
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<meta name="description" content="declaration: module: org.apache.jena.arq, package: org.apache.jena.riot, class: RDFParser">
<meta name="generator" content="javadoc/ClassWriterImpl">
<link rel="stylesheet" type="text/css" href="../../../../../stylesheet.css" title="Style">
<link rel="stylesheet" type="text/css" href="../../../../../script-dir/jquery-ui.min.css" title="Style">
<link rel="stylesheet" type="text/css" href="../../../../../jquery-ui.overrides.css" title="Style">
<script type="text/javascript" src="../../../../../script.js"></script>
<script type="text/javascript" src="../../../../../script-dir/jquery-3.6.1.min.js"></script>
<script type="text/javascript" src="../../../../../script-dir/jquery-ui.min.js"></script>
</head>
<body class="class-declaration-page">
<script type="text/javascript">var evenRowColor = "even-row-color";
var oddRowColor = "odd-row-color";
var tableTab = "table-tab";
var activeTableTab = "active-table-tab";
var pathtoroot = "../../../../../";
loadScripts(document, 'script');</script>
<noscript>
<div>JavaScript is disabled on your browser.</div>
</noscript>
<div class="flex-box">
<header role="banner" class="flex-header">
<nav role="navigation">
<!-- ========= START OF TOP NAVBAR ======= -->
<div class="top-nav" id="navbar-top">
<div class="skip-nav"><a href="#skip-navbar-top" title="Skip navigation links">Skip navigation links</a></div>
<ul id="navbar-top-firstrow" class="nav-list" title="Navigation">
<li><a href="../../../../module-summary.html">Module</a></li>
<li><a href="package-summary.html">Package</a></li>
<li class="nav-bar-cell1-rev">Class</li>
<li><a href="class-use/RDFParser.html">Use</a></li>
<li><a href="package-tree.html">Tree</a></li>
<li><a href="../../../../../deprecated-list.html">Deprecated</a></li>
<li><a href="../../../../../index-all.html">Index</a></li>
<li><a href="../../../../../help-doc.html#class">Help</a></li>
</ul>
</div>
<div class="sub-nav">
<div>
<ul class="sub-nav-list">
<li>Summary:&nbsp;</li>
<li>Nested&nbsp;|&nbsp;</li>
<li>Field&nbsp;|&nbsp;</li>
<li>Constr&nbsp;|&nbsp;</li>
<li><a href="#method-summary">Method</a></li>
</ul>
<ul class="sub-nav-list">
<li>Detail:&nbsp;</li>
<li>Field&nbsp;|&nbsp;</li>
<li>Constr&nbsp;|&nbsp;</li>
<li><a href="#method-detail">Method</a></li>
</ul>
</div>
<div class="nav-list-search"><label for="search-input">SEARCH:</label>
<input type="text" id="search-input" value="search" disabled="disabled">
<input type="reset" id="reset-button" value="reset" disabled="disabled">
</div>
</div>
<!-- ========= END OF TOP NAVBAR ========= -->
<span class="skip-nav" id="skip-navbar-top"></span></nav>
</header>
<div class="flex-content">
<main role="main">
<!-- ======== START OF CLASS DATA ======== -->
<div class="header">
<div class="sub-title"><span class="module-label-in-type">Module</span>&nbsp;<a href="../../../../module-summary.html">org.apache.jena.arq</a></div>
<div class="sub-title"><span class="package-label-in-type">Package</span>&nbsp;<a href="package-summary.html">org.apache.jena.riot</a></div>
<h1 title="Class RDFParser" class="title">Class RDFParser</h1>
</div>
<div class="inheritance" title="Inheritance Tree"><a href="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/lang/Object.html" title="class or interface in java.lang" class="external-link">java.lang.Object</a>
<div class="inheritance">org.apache.jena.riot.RDFParser</div>
</div>
<section class="class-description" id="class-description">
<hr>
<div class="type-signature"><span class="modifiers">public class </span><span class="element-name type-name-label">RDFParser</span>
<span class="extends-implements">extends <a href="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/lang/Object.html" title="class or interface in java.lang" class="external-link">Object</a></span></div>
<div class="block">An <a href="RDFParser.html" title="class in org.apache.jena.riot"><code>RDFParser</code></a> is a process that will generate triples and quads;
<a href="RDFParserBuilder.html" title="class in org.apache.jena.riot"><code>RDFParserBuilder</code></a> provides the means to create parsers.
<p>
An <a href="RDFParser.html" title="class in org.apache.jena.riot"><code>RDFParser</code></a> has a predefined source; the target for output is given when the
"parse" step is called. It can be used multiple times in which case the same source
is reread. The destination can vary. The application is responsible for concurrency of
the destination of the parse operation.
<p>
Parser output is sent to a <a href="system/StreamRDF.html" title="interface in org.apache.jena.riot.system"><code>StreamRDF</code></a>.
The general process is
<pre>
StreamRDF destination = ...
RDFParser parser = RDFParser.create().source("filename.ttl").build();
parser.parse(destination);
</pre>
There are various convenience forms to perform common tasks such as
to parse a file and create a <code>Model</code>:
<pre>
Model model = RDFParser.source("filename.ttl").toModel();
</pre></div>
<dl class="notes">
<dt>See Also:</dt>
<dd>
<ul class="see-list-long">
<li><a href="ReaderRIOT.html" title="interface in org.apache.jena.riot"><code>The interface to the syntax parsing process for each RDF syntax.</code></a></li>
</ul>
</dd>
</dl>
</section>
<section class="summary">
<ul class="summary-list">
<!-- ========== METHOD SUMMARY =========== -->
<li>
<section class="method-summary" id="method-summary">
<h2>Method Summary</h2>
<div id="method-summary-table">
<div class="table-tabs" role="tablist" aria-orientation="horizontal"><button id="method-summary-table-tab0" role="tab" aria-selected="true" aria-controls="method-summary-table.tabpanel" tabindex="0" onkeydown="switchTab(event)" onclick="show('method-summary-table', 'method-summary-table', 3)" class="active-table-tab">All Methods</button><button id="method-summary-table-tab1" role="tab" aria-selected="false" aria-controls="method-summary-table.tabpanel" tabindex="-1" onkeydown="switchTab(event)" onclick="show('method-summary-table', 'method-summary-table-tab1', 3)" class="table-tab">Static Methods</button><button id="method-summary-table-tab2" role="tab" aria-selected="false" aria-controls="method-summary-table.tabpanel" tabindex="-1" onkeydown="switchTab(event)" onclick="show('method-summary-table', 'method-summary-table-tab2', 3)" class="table-tab">Instance Methods</button><button id="method-summary-table-tab4" role="tab" aria-selected="false" aria-controls="method-summary-table.tabpanel" tabindex="-1" onkeydown="switchTab(event)" onclick="show('method-summary-table', 'method-summary-table-tab4', 3)" class="table-tab">Concrete Methods</button><button id="method-summary-table-tab6" role="tab" aria-selected="false" aria-controls="method-summary-table.tabpanel" tabindex="-1" onkeydown="switchTab(event)" onclick="show('method-summary-table', 'method-summary-table-tab6', 3)" class="table-tab">Deprecated Methods</button></div>
<div id="method-summary-table.tabpanel" role="tabpanel">
<div class="summary-table three-column-summary" aria-labelledby="method-summary-table-tab0">
<div class="table-header col-first">Modifier and Type</div>
<div class="table-header col-second">Method</div>
<div class="table-header col-last">Description</div>
<div class="col-first even-row-color method-summary-table method-summary-table-tab1 method-summary-table-tab4"><code>static <a href="RDFParserBuilder.html" title="class in org.apache.jena.riot">RDFParserBuilder</a></code></div>
<div class="col-second even-row-color method-summary-table method-summary-table-tab1 method-summary-table-tab4"><code><a href="#create()" class="member-name-link">create</a>()</code></div>
<div class="col-last even-row-color method-summary-table method-summary-table-tab1 method-summary-table-tab4">
<div class="block">Create an <a href="RDFParserBuilder.html" title="class in org.apache.jena.riot"><code>RDFParserBuilder</code></a>.</div>
</div>
<div class="col-first odd-row-color method-summary-table method-summary-table-tab1 method-summary-table-tab4 method-summary-table-tab6"><code>static <a href="RDFParserBuilder.html" title="class in org.apache.jena.riot">RDFParserBuilder</a></code></div>
<div class="col-second odd-row-color method-summary-table method-summary-table-tab1 method-summary-table-tab4 method-summary-table-tab6"><code><a href="#fromString(java.lang.String)" class="member-name-link">fromString</a><wbr>(<a href="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/lang/String.html" title="class or interface in java.lang" class="external-link">String</a>&nbsp;string)</code></div>
<div class="col-last odd-row-color method-summary-table method-summary-table-tab1 method-summary-table-tab4 method-summary-table-tab6">
<div class="block"><span class="deprecated-label">Deprecated.</span>
<div class="deprecation-comment">Use <a href="#fromString(java.lang.String,org.apache.jena.riot.Lang)"><code>fromString(String, Lang)</code></a></div>
</div>
</div>
<div class="col-first even-row-color method-summary-table method-summary-table-tab1 method-summary-table-tab4"><code>static <a href="RDFParserBuilder.html" title="class in org.apache.jena.riot">RDFParserBuilder</a></code></div>
<div class="col-second even-row-color method-summary-table method-summary-table-tab1 method-summary-table-tab4"><code><a href="#fromString(java.lang.String,org.apache.jena.riot.Lang)" class="member-name-link">fromString</a><wbr>(<a href="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/lang/String.html" title="class or interface in java.lang" class="external-link">String</a>&nbsp;string,
<a href="Lang.html" title="class in org.apache.jena.riot">Lang</a>&nbsp;lang)</code></div>
<div class="col-last even-row-color method-summary-table method-summary-table-tab1 method-summary-table-tab4">
<div class="block">Create an <a href="RDFParserBuilder.html" title="class in org.apache.jena.riot"><code>RDFParserBuilder</code></a> and set content to be parsed
together with the RDF syntax language.</div>
</div>
<div class="col-first odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4"><code>void</code></div>
<div class="col-second odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4"><code><a href="#parse(org.apache.jena.graph.Graph)" class="member-name-link">parse</a><wbr>(org.apache.jena.graph.Graph&nbsp;graph)</code></div>
<div class="col-last odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4">
<div class="block">Parse the source, sending the results to a <code>Graph</code>.</div>
</div>
<div class="col-first even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4"><code>void</code></div>
<div class="col-second even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4"><code><a href="#parse(org.apache.jena.query.Dataset)" class="member-name-link">parse</a><wbr>(<a href="../query/Dataset.html" title="interface in org.apache.jena.query">Dataset</a>&nbsp;dataset)</code></div>
<div class="col-last even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4">
<div class="block">Parse the source, sending the results to a <a href="../query/Dataset.html" title="interface in org.apache.jena.query"><code>Dataset</code></a>.</div>
</div>
<div class="col-first odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4"><code>void</code></div>
<div class="col-second odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4"><code><a href="#parse(org.apache.jena.rdf.model.Model)" class="member-name-link">parse</a><wbr>(org.apache.jena.rdf.model.Model&nbsp;model)</code></div>
<div class="col-last odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4">
<div class="block">Parse the source, sending the results to a <code>Model</code>.</div>
</div>
<div class="col-first even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4"><code>void</code></div>
<div class="col-second even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4"><code><a href="#parse(org.apache.jena.riot.system.StreamRDF)" class="member-name-link">parse</a><wbr>(<a href="system/StreamRDF.html" title="interface in org.apache.jena.riot.system">StreamRDF</a>&nbsp;destination)</code></div>
<div class="col-last even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4">
<div class="block">Parse the source, sending the results to a <a href="system/StreamRDF.html" title="interface in org.apache.jena.riot.system"><code>StreamRDF</code></a>.</div>
</div>
<div class="col-first odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4"><code>void</code></div>
<div class="col-second odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4"><code><a href="#parse(org.apache.jena.sparql.core.DatasetGraph)" class="member-name-link">parse</a><wbr>(<a href="../sparql/core/DatasetGraph.html" title="interface in org.apache.jena.sparql.core">DatasetGraph</a>&nbsp;dataset)</code></div>
<div class="col-last odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4">
<div class="block">Parse the source, sending the results to a <a href="../sparql/core/DatasetGraph.html" title="interface in org.apache.jena.sparql.core"><code>DatasetGraph</code></a>.</div>
</div>
<div class="col-first even-row-color method-summary-table method-summary-table-tab1 method-summary-table-tab4"><code>static <a href="RDFParserBuilder.html" title="class in org.apache.jena.riot">RDFParserBuilder</a></code></div>
<div class="col-second even-row-color method-summary-table method-summary-table-tab1 method-summary-table-tab4"><code><a href="#source(java.io.InputStream)" class="member-name-link">source</a><wbr>(<a href="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/io/InputStream.html" title="class or interface in java.io" class="external-link">InputStream</a>&nbsp;input)</code></div>
<div class="col-last even-row-color method-summary-table method-summary-table-tab1 method-summary-table-tab4">
<div class="block">Create an <a href="RDFParserBuilder.html" title="class in org.apache.jena.riot"><code>RDFParserBuilder</code></a> and set the source to <a href="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/io/InputStream.html" title="class or interface in java.io" class="external-link"><code>InputStream</code></a>.</div>
</div>
<div class="col-first odd-row-color method-summary-table method-summary-table-tab1 method-summary-table-tab4"><code>static <a href="RDFParserBuilder.html" title="class in org.apache.jena.riot">RDFParserBuilder</a></code></div>
<div class="col-second odd-row-color method-summary-table method-summary-table-tab1 method-summary-table-tab4"><code><a href="#source(java.lang.String)" class="member-name-link">source</a><wbr>(<a href="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/lang/String.html" title="class or interface in java.lang" class="external-link">String</a>&nbsp;uriOrFile)</code></div>
<div class="col-last odd-row-color method-summary-table method-summary-table-tab1 method-summary-table-tab4">
<div class="block">Create an <a href="RDFParserBuilder.html" title="class in org.apache.jena.riot"><code>RDFParserBuilder</code></a> and set the source to the URI, which
can be a filename.</div>
</div>
<div class="col-first even-row-color method-summary-table method-summary-table-tab1 method-summary-table-tab4"><code>static <a href="RDFParserBuilder.html" title="class in org.apache.jena.riot">RDFParserBuilder</a></code></div>
<div class="col-second even-row-color method-summary-table method-summary-table-tab1 method-summary-table-tab4"><code><a href="#source(java.nio.file.Path)" class="member-name-link">source</a><wbr>(<a href="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/nio/file/Path.html" title="class or interface in java.nio.file" class="external-link">Path</a>&nbsp;path)</code></div>
<div class="col-last even-row-color method-summary-table method-summary-table-tab1 method-summary-table-tab4">
<div class="block">Create an <a href="RDFParserBuilder.html" title="class in org.apache.jena.riot"><code>RDFParserBuilder</code></a> and set the source to the
<a href="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/nio/file/Path.html" title="class or interface in java.nio.file" class="external-link"><code>Path</code></a>.</div>
</div>
<div class="col-first odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4"><code><a href="../query/Dataset.html" title="interface in org.apache.jena.query">Dataset</a></code></div>
<div class="col-second odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4"><code><a href="#toDataset()" class="member-name-link">toDataset</a>()</code></div>
<div class="col-last odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4">
<div class="block">Parse the source in to a fresh <a href="../query/Dataset.html" title="interface in org.apache.jena.query"><code>Dataset</code></a> and return the dataset.</div>
</div>
<div class="col-first even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4"><code><a href="../sparql/core/DatasetGraph.html" title="interface in org.apache.jena.sparql.core">DatasetGraph</a></code></div>
<div class="col-second even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4"><code><a href="#toDatasetGraph()" class="member-name-link">toDatasetGraph</a>()</code></div>
<div class="col-last even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4">
<div class="block">Parse the source in to a fresh <a href="../sparql/core/DatasetGraph.html" title="interface in org.apache.jena.sparql.core"><code>DatasetGraph</code></a> and return the DatasetGraph.</div>
</div>
<div class="col-first odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4"><code>org.apache.jena.graph.Graph</code></div>
<div class="col-second odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4"><code><a href="#toGraph()" class="member-name-link">toGraph</a>()</code></div>
<div class="col-last odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4">
<div class="block">Parse the source in to a fresh <code>Graph</code> and return the graph.</div>
</div>
<div class="col-first even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4"><code>org.apache.jena.rdf.model.Model</code></div>
<div class="col-second even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4"><code><a href="#toModel()" class="member-name-link">toModel</a>()</code></div>
<div class="col-last even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4">
<div class="block">Parse the source in to a fresh <code>Model</code> and return the model.</div>
</div>
</div>
</div>
</div>
<div class="inherited-list">
<h3 id="methods-inherited-from-class-java.lang.Object">Methods inherited from class&nbsp;java.lang.<a href="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/lang/Object.html" title="class or interface in java.lang" class="external-link">Object</a></h3>
<code><a href="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/lang/Object.html#equals(java.lang.Object)" title="class or interface in java.lang" class="external-link">equals</a>, <a href="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/lang/Object.html#getClass()" title="class or interface in java.lang" class="external-link">getClass</a>, <a href="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/lang/Object.html#hashCode()" title="class or interface in java.lang" class="external-link">hashCode</a>, <a href="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/lang/Object.html#notify()" title="class or interface in java.lang" class="external-link">notify</a>, <a href="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/lang/Object.html#notifyAll()" title="class or interface in java.lang" class="external-link">notifyAll</a>, <a href="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/lang/Object.html#toString()" title="class or interface in java.lang" class="external-link">toString</a>, <a href="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/lang/Object.html#wait()" title="class or interface in java.lang" class="external-link">wait</a>, <a href="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/lang/Object.html#wait(long)" title="class or interface in java.lang" class="external-link">wait</a>, <a href="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/lang/Object.html#wait(long,int)" title="class or interface in java.lang" class="external-link">wait</a></code></div>
</section>
</li>
</ul>
</section>
<section class="details">
<ul class="details-list">
<!-- ============ METHOD DETAIL ========== -->
<li>
<section class="method-details" id="method-detail">
<h2>Method Details</h2>
<ul class="member-list">
<li>
<section class="detail" id="create()">
<h3>create</h3>
<div class="member-signature"><span class="modifiers">public static</span>&nbsp;<span class="return-type"><a href="RDFParserBuilder.html" title="class in org.apache.jena.riot">RDFParserBuilder</a></span>&nbsp;<span class="element-name">create</span>()</div>
<div class="block">Create an <a href="RDFParserBuilder.html" title="class in org.apache.jena.riot"><code>RDFParserBuilder</code></a>.
<p>
Often used in a pattern such as:
<pre>
RDFParser.create()
.source("data.ttl")
.parse(graph);
</pre></div>
</section>
</li>
<li>
<section class="detail" id="source(java.nio.file.Path)">
<h3>source</h3>
<div class="member-signature"><span class="modifiers">public static</span>&nbsp;<span class="return-type"><a href="RDFParserBuilder.html" title="class in org.apache.jena.riot">RDFParserBuilder</a></span>&nbsp;<span class="element-name">source</span><wbr><span class="parameters">(<a href="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/nio/file/Path.html" title="class or interface in java.nio.file" class="external-link">Path</a>&nbsp;path)</span></div>
<div class="block">Create an <a href="RDFParserBuilder.html" title="class in org.apache.jena.riot"><code>RDFParserBuilder</code></a> and set the source to the
<a href="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/nio/file/Path.html" title="class or interface in java.nio.file" class="external-link"><code>Path</code></a>.
<p>
This is a shortcut for <code>RDFParser.create().source(path)</code>.</div>
<dl class="notes">
<dt>Parameters:</dt>
<dd><code>path</code> - </dd>
<dt>Returns:</dt>
<dd>RDFParserBuilder</dd>
</dl>
</section>
</li>
<li>
<section class="detail" id="source(java.lang.String)">
<h3>source</h3>
<div class="member-signature"><span class="modifiers">public static</span>&nbsp;<span class="return-type"><a href="RDFParserBuilder.html" title="class in org.apache.jena.riot">RDFParserBuilder</a></span>&nbsp;<span class="element-name">source</span><wbr><span class="parameters">(<a href="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/lang/String.html" title="class or interface in java.lang" class="external-link">String</a>&nbsp;uriOrFile)</span></div>
<div class="block">Create an <a href="RDFParserBuilder.html" title="class in org.apache.jena.riot"><code>RDFParserBuilder</code></a> and set the source to the URI, which
can be a filename.
<p>
This is a shortcut for <code>RDFParser.create().source(uriOrFile)</code>.</div>
<dl class="notes">
<dt>Parameters:</dt>
<dd><code>uriOrFile</code> - </dd>
<dt>Returns:</dt>
<dd>RDFParserBuilder</dd>
</dl>
</section>
</li>
<li>
<section class="detail" id="fromString(java.lang.String)">
<h3>fromString</h3>
<div class="member-signature"><span class="annotations"><a href="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/lang/Deprecated.html" title="class or interface in java.lang" class="external-link">@Deprecated</a>
</span><span class="modifiers">public static</span>&nbsp;<span class="return-type"><a href="RDFParserBuilder.html" title="class in org.apache.jena.riot">RDFParserBuilder</a></span>&nbsp;<span class="element-name">fromString</span><wbr><span class="parameters">(<a href="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/lang/String.html" title="class or interface in java.lang" class="external-link">String</a>&nbsp;string)</span></div>
<div class="deprecation-block"><span class="deprecated-label">Deprecated.</span>
<div class="deprecation-comment">Use <a href="#fromString(java.lang.String,org.apache.jena.riot.Lang)"><code>fromString(String, Lang)</code></a></div>
</div>
<div class="block">Create an <a href="RDFParserBuilder.html" title="class in org.apache.jena.riot"><code>RDFParserBuilder</code></a> and set content to be parsed to the
string. The syntax must be set with <code>.lang(...)</code>.
<p>
Shortcut for <code>RDFParser.create.fromString(string)</code>.</div>
<dl class="notes">
<dt>Parameters:</dt>
<dd><code>string</code> - </dd>
<dt>Returns:</dt>
<dd>RDFParserBuilder</dd>
</dl>
</section>
</li>
<li>
<section class="detail" id="fromString(java.lang.String,org.apache.jena.riot.Lang)">
<h3>fromString</h3>
<div class="member-signature"><span class="modifiers">public static</span>&nbsp;<span class="return-type"><a href="RDFParserBuilder.html" title="class in org.apache.jena.riot">RDFParserBuilder</a></span>&nbsp;<span class="element-name">fromString</span><wbr><span class="parameters">(<a href="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/lang/String.html" title="class or interface in java.lang" class="external-link">String</a>&nbsp;string,
<a href="Lang.html" title="class in org.apache.jena.riot">Lang</a>&nbsp;lang)</span></div>
<div class="block">Create an <a href="RDFParserBuilder.html" title="class in org.apache.jena.riot"><code>RDFParserBuilder</code></a> and set content to be parsed
together with the RDF syntax language.
<p>
Shortcut for <code>RDFParser.create.fromString(string).lang(lang)</code>.</div>
<dl class="notes">
<dt>Parameters:</dt>
<dd><code>string</code> - </dd>
<dd><code>lang</code> - </dd>
<dt>Returns:</dt>
<dd>RDFParserBuilder</dd>
</dl>
</section>
</li>
<li>
<section class="detail" id="source(java.io.InputStream)">
<h3>source</h3>
<div class="member-signature"><span class="modifiers">public static</span>&nbsp;<span class="return-type"><a href="RDFParserBuilder.html" title="class in org.apache.jena.riot">RDFParserBuilder</a></span>&nbsp;<span class="element-name">source</span><wbr><span class="parameters">(<a href="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/io/InputStream.html" title="class or interface in java.io" class="external-link">InputStream</a>&nbsp;input)</span></div>
<div class="block">Create an <a href="RDFParserBuilder.html" title="class in org.apache.jena.riot"><code>RDFParserBuilder</code></a> and set the source to <a href="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/io/InputStream.html" title="class or interface in java.io" class="external-link"><code>InputStream</code></a>.
The <a href="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/io/InputStream.html" title="class or interface in java.io" class="external-link"><code>InputStream</code></a> will be closed when the
parser is called and the parser can not be reused.
The syntax must be set with <code>.lang(...)</code>.
<p>
This is a shortcut for <code>RDFParser.create().source(input)</code>.</div>
<dl class="notes">
<dt>Parameters:</dt>
<dd><code>input</code> - </dd>
<dt>Returns:</dt>
<dd>RDFParserBuilder</dd>
</dl>
</section>
</li>
<li>
<section class="detail" id="parse(org.apache.jena.graph.Graph)">
<h3>parse</h3>
<div class="member-signature"><span class="modifiers">public</span>&nbsp;<span class="return-type">void</span>&nbsp;<span class="element-name">parse</span><wbr><span class="parameters">(org.apache.jena.graph.Graph&nbsp;graph)</span></div>
<div class="block">Parse the source, sending the results to a <code>Graph</code>.
<p>
The source must be for
triples; any quads are discarded.</div>
</section>
</li>
<li>
<section class="detail" id="parse(org.apache.jena.rdf.model.Model)">
<h3>parse</h3>
<div class="member-signature"><span class="modifiers">public</span>&nbsp;<span class="return-type">void</span>&nbsp;<span class="element-name">parse</span><wbr><span class="parameters">(org.apache.jena.rdf.model.Model&nbsp;model)</span></div>
<div class="block">Parse the source, sending the results to a <code>Model</code>.
<p>
The source must be for
triples; any quads are discarded.
<p>
This method is equivalent to <code>parse(model.getGraph())</code>.</div>
</section>
</li>
<li>
<section class="detail" id="parse(org.apache.jena.sparql.core.DatasetGraph)">
<h3>parse</h3>
<div class="member-signature"><span class="modifiers">public</span>&nbsp;<span class="return-type">void</span>&nbsp;<span class="element-name">parse</span><wbr><span class="parameters">(<a href="../sparql/core/DatasetGraph.html" title="interface in org.apache.jena.sparql.core">DatasetGraph</a>&nbsp;dataset)</span></div>
<div class="block">Parse the source, sending the results to a <a href="../sparql/core/DatasetGraph.html" title="interface in org.apache.jena.sparql.core"><code>DatasetGraph</code></a>.</div>
</section>
</li>
<li>
<section class="detail" id="parse(org.apache.jena.query.Dataset)">
<h3>parse</h3>
<div class="member-signature"><span class="modifiers">public</span>&nbsp;<span class="return-type">void</span>&nbsp;<span class="element-name">parse</span><wbr><span class="parameters">(<a href="../query/Dataset.html" title="interface in org.apache.jena.query">Dataset</a>&nbsp;dataset)</span></div>
<div class="block">Parse the source, sending the results to a <a href="../query/Dataset.html" title="interface in org.apache.jena.query"><code>Dataset</code></a>.
This method is equivalent to <code>parse(dataset.asDatasetGraph())</code>.</div>
</section>
</li>
<li>
<section class="detail" id="toGraph()">
<h3>toGraph</h3>
<div class="member-signature"><span class="modifiers">public</span>&nbsp;<span class="return-type">org.apache.jena.graph.Graph</span>&nbsp;<span class="element-name">toGraph</span>()</div>
<div class="block">Parse the source in to a fresh <code>Graph</code> and return the graph.
<p>
The source must be for triples; any quads are discarded.</div>
</section>
</li>
<li>
<section class="detail" id="toModel()">
<h3>toModel</h3>
<div class="member-signature"><span class="modifiers">public</span>&nbsp;<span class="return-type">org.apache.jena.rdf.model.Model</span>&nbsp;<span class="element-name">toModel</span>()</div>
<div class="block">Parse the source in to a fresh <code>Model</code> and return the model.
<p>
The source must be for triples; any quads are discarded.</div>
</section>
</li>
<li>
<section class="detail" id="toDataset()">
<h3>toDataset</h3>
<div class="member-signature"><span class="modifiers">public</span>&nbsp;<span class="return-type"><a href="../query/Dataset.html" title="interface in org.apache.jena.query">Dataset</a></span>&nbsp;<span class="element-name">toDataset</span>()</div>
<div class="block">Parse the source in to a fresh <a href="../query/Dataset.html" title="interface in org.apache.jena.query"><code>Dataset</code></a> and return the dataset.</div>
</section>
</li>
<li>
<section class="detail" id="toDatasetGraph()">
<h3>toDatasetGraph</h3>
<div class="member-signature"><span class="modifiers">public</span>&nbsp;<span class="return-type"><a href="../sparql/core/DatasetGraph.html" title="interface in org.apache.jena.sparql.core">DatasetGraph</a></span>&nbsp;<span class="element-name">toDatasetGraph</span>()</div>
<div class="block">Parse the source in to a fresh <a href="../sparql/core/DatasetGraph.html" title="interface in org.apache.jena.sparql.core"><code>DatasetGraph</code></a> and return the DatasetGraph.</div>
</section>
</li>
<li>
<section class="detail" id="parse(org.apache.jena.riot.system.StreamRDF)">
<h3>parse</h3>
<div class="member-signature"><span class="modifiers">public</span>&nbsp;<span class="return-type">void</span>&nbsp;<span class="element-name">parse</span><wbr><span class="parameters">(<a href="system/StreamRDF.html" title="interface in org.apache.jena.riot.system">StreamRDF</a>&nbsp;destination)</span></div>
<div class="block">Parse the source, sending the results to a <a href="system/StreamRDF.html" title="interface in org.apache.jena.riot.system"><code>StreamRDF</code></a>.</div>
</section>
</li>
</ul>
</section>
</li>
</ul>
</section>
<!-- ========= END OF CLASS DATA ========= -->
</main>
<footer role="contentinfo">
<hr>
<p class="legal-copy"><small>Licensed under the Apache License, Version 2.0</small></p>
</footer>
</div>
</div>
</body>
</html>