You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@jena.apache.org by an...@apache.org on 2023/03/25 12:11:46 UTC

[jena-site] branch rdfxml created (now f58dade34)

This is an automated email from the ASF dual-hosted git repository.

andy pushed a change to branch rdfxml
in repository https://gitbox.apache.org/repos/asf/jena-site.git


      at f58dade34 Legacy RDF/XML documention.

This branch includes the following new commits:

     new f30ee7170 Formatting
     new f58dade34 Legacy RDF/XML documention.

The 2 revisions listed above as "new" are entirely new to this
repository and will be described in separate emails.  The revisions
listed as "add" were already present in the repository and have only
been added to this reference.



[jena-site] 02/02: Legacy RDF/XML documention.

Posted by an...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

andy pushed a commit to branch rdfxml
in repository https://gitbox.apache.org/repos/asf/jena-site.git

commit f58dade34a1c6273328cb81166caaa3b9cacdbd2
Author: Andy Seaborne <an...@apache.org>
AuthorDate: Tue Mar 21 21:30:23 2023 +0000

    Legacy RDF/XML documention.
---
 source/documentation/io/__index.md                 |   2 +-
 source/documentation/io/{ => arp}/arp.md           |   2 +-
 source/documentation/io/{ => arp}/arp_sax.md       |   0
 .../documentation/io/{ => arp}/arp_standalone.md   |   0
 source/documentation/io/rdfxml-input.md            | 145 ++++++++++++
 source/documentation/io/rdfxml-io.md               |  71 ++++++
 source/documentation/io/rdfxml-output.md           | 243 +++++++++++++++++++++
 source/documentation/io/rdfxml_howto.md            |   4 +
 8 files changed, 465 insertions(+), 2 deletions(-)

diff --git a/source/documentation/io/__index.md b/source/documentation/io/__index.md
index 6214bdb41..7a19f6ba9 100644
--- a/source/documentation/io/__index.md
+++ b/source/documentation/io/__index.md
@@ -10,7 +10,7 @@ This page details the setup of RDF I/O technology (RIOT).
 * [Reading RDF in Jena](rdf-input.html)
 * [Writing RDF in Jena](rdf-output.html)
 * [Working with RDF Streams](streaming-io.html)
-* [Additional details on working with RDF/XML](rdfxml_howto.html)
+* [Additional details on working with RDF/XML](rdfxml-io.html)
 
 ## Formats
 
diff --git a/source/documentation/io/arp.md b/source/documentation/io/arp/arp.md
similarity index 98%
rename from source/documentation/io/arp.md
rename to source/documentation/io/arp/arp.md
index c6b688e48..99d219c30 100644
--- a/source/documentation/io/arp.md
+++ b/source/documentation/io/arp/arp.md
@@ -1,5 +1,5 @@
 ---
-title: RDF/XML Handling in Jena
+title: RDF/XML Input in Jena
 ---
 
 This section details the Jena RDF/XML parser.
diff --git a/source/documentation/io/arp_sax.md b/source/documentation/io/arp/arp_sax.md
similarity index 100%
rename from source/documentation/io/arp_sax.md
rename to source/documentation/io/arp/arp_sax.md
diff --git a/source/documentation/io/arp_standalone.md b/source/documentation/io/arp/arp_standalone.md
similarity index 100%
rename from source/documentation/io/arp_standalone.md
rename to source/documentation/io/arp/arp_standalone.md
diff --git a/source/documentation/io/rdfxml-input.md b/source/documentation/io/rdfxml-input.md
new file mode 100644
index 000000000..6e831ecf2
--- /dev/null
+++ b/source/documentation/io/rdfxml-input.md
@@ -0,0 +1,145 @@
+---
+title: Jena RDF/XML Input How-To
+---
+
+_Legacy Documentation : may not be up-to-date_
+
+Original [RDF/XML HowTo](rdfxml_howto.html).
+
+---
+
+This is a guide to the RDF/XML legacy input subsystem of Jena, ARP.
+
+## Advanced RDF/XML Input
+
+For access to these advanced features, first get an `RDFReader`
+object that is an instance of an ARP parser, by using the
+[`getReader`](/documentation/javadoc/jena/org/apache/jena/rdf/model/RDFReaderF.html#getReader())`()`
+method on any `Model`. It is then configured using the
+[`setProperty`](/documentation/javadoc/jena/org/apache/jena/rdfxml/xmlinput0/JenaReader.html#setProperty(java.lang.String, java.lang.Object))`(String, Object)`
+method. This changes the properties for parsing RDF/XML. Many of
+the properties change the RDF parser, some change the XML parser.
+(The Jena RDF/XML parser, ARP, implements the
+[RDF grammar](http://www.w3.org/TR/rdf-syntax-grammar/#section-Infoset-Grammar)
+over a [Xerces2-J](http://xml.apache.org/xerces2-j/index.html) XML
+parser). However, changing the features and properties of the XML
+parser is not likely to be useful, but was easy to implement.
+
+[`setProperty`](/documentation/javadoc/jena/org/apache/jena/rdfxml/xmlinput0/JenaReader.html#setProperty(java.lang.String, java.lang.Object))`(String, Object)`
+can be used to set and get:
+
+- ARP properties
+   <br /> These allow fine grain control over the extensive error
+   reporting capabilities of ARP. And are detailed directly below.
+- SAX2 features
+  <br />See
+  [Xerces features](http://xml.apache.org/xerces2-j/features.html).
+  Value should be given as a String `"true"` or `"false"` or a `Boolean`.
+- SAX2 properties
+  <br /> See [Xerces properties](http://xml.apache.org/xerces2-j/properties.html).
+- Xerces features
+  <br /> See [Xerces features](http://xml.apache.org/xerces2-j/features.html).
+    Value should be given as a String `"true"` or `"false"` or a `Boolean`.
+- Xerces properties
+  <br /> See [Xerces properties](http://xml.apache.org/xerces2-j/properties.html).
+
+### ARP properties
+
+An ARP property is referred to either by its property name, (see
+below) or by an absolute URL of the form
+`http://jena.hpl.hp.com/arp/properties/<PropertyName>`. The value
+should be a String, an Integer or a Boolean depending on the
+property.
+
+ARP property names and string values are case insensitive.
+
+Property Name | Description | Value class | Legal Values
+------------- | ----------- | ----------- | ------------
+`iri-rules` | Set the engine for checking and resolving. `"strict"` sets the IRI engine with rules for valid IRIs, XLink and RDF; it does not permit spaces in IRIs. `"iri"`sets the IRI engine to IRI ([RFC 3986](http://www.ietf.org/rfc/rfc3986.txt), [RFC 3987](http://www.ietf.org/rfc/rfc3987.txt)) `.` The default is `"lax"`(for backwards compatibility)`,` the rules for RDF URI references only, which does permit spaces although the use of spaces is not good practice. | String | `lax`<br /> [...]
+`error-mode`| [`ARPOptions.setDefaultErrorMode()`](/documentation/javadoc/jena/org/apache/jena/rdfxml/xmlinput0/ARPOptions.html#setDefaultErrorMode()) <br />[`ARPOptions.setLaxErrorMode()`](/documentation/javadoc/jena/org/apache/jena/rdfxml/xmlinput0/ARPOptions.html#setLaxErrorMode())<br />[`ARPOptions.setStrictErrorMode()`](/documentation/javadoc/jena/org/apache/jena/rdfxml0/xmlinput/ARPOptions.html#setStrictErrorMode())<br />[`ARPOptions.setStrictErrorMode(int)`](/documentation/javadoc [...]
+`embedding` | [`ARPOptions.setEmbedding(boolean)`](/documentation/javadoc/jena/org/apache/jena/rdfxml0/xmlinput/ARPOptions.html#setEmbedding(boolean)) <br />This sets ARP to look for RDF embedded within an enclosing XML document. | `String` or `Boolean` | `true`<br />`false`
+`ERR_<XXX>` <br />`WARN_<XXX>`<br />`IGN_<XXX>` | See [`ARPErrorNumbers`](/documentation/javadoc/jena/org/apache/jena/rdfxml0/xmlinput/ARPErrorNumbers.html) for a complete list of the error conditions detected. Setting one of these properties is equivalent to the method [`ARPOptions.setErrorMode(int, int)`](/documentation/javadoc/jena/org/apache/jena/rdfxml0/xmlinput/ARPOptions.html#setErrorMode(int,%20int)). Thus fine-grained control over the behaviour in response to specific error cond [...]
+
+To set ARP properties, create a map of values to be set and put this in parser context:
+
+```
+    Map<String, Object> properties = new HashMap<>();
+    // See class ARPErrorNumbers for the possible ARP properties.
+    properties.put("WARN_BAD_NAME", "EM_IGNORE");
+
+    // Build and run a parser
+    Model model = RDFParser.create()
+        .lang(Lang.RDFXML)
+        .source(...)
+        .set(SysRIOT.sysRdfReaderProperties, properties)
+        .base("http://base/")
+        .toModel();
+    System.out.println("== Parsed data output in Turtle");
+    RDFDataMgr.write(System.out,  model, Lang.TURTLE);
+```
+
+See example
+[ExRIOT_RDFXML_ReaderProperties.java](https://github.com/apache/jena/blob/main/jena-examples/src/main/java/arq/examples/riot/ExRIOT_RDFXML_ReaderProperties.java).
+
+<b>Legacy Example</b>
+
+As an example, if you are working in an environment with legacy RDF
+data that uses unqualified RDF attributes such as "about" instead
+of "rdf:about", then the following code is appropriate:
+
+    Model m = ModelFactory.createDefaultModel();
+    RDFReader arp = m.getReader();
+    m = null; // m is no longer needed.
+    // initialize arp
+    // Do not warn on use of unqualified RDF attributes.
+    arp.setProperty("WARN_UNQUALIFIED_RDF_ATTRIBUTE","EM_IGNORE");
+
+    …
+
+    InputStream in = new FileInputStream(fname);
+    arp.read(m,in,url);
+    in.close();
+
+As a second example, suppose you wish to work in strict mode, but
+allow `"daml:collection"`, the following works:
+
+     …
+     arp.setProperty("error-mode", "strict" );
+     arp.setProperty("IGN_DAML_COLLECTION","EM_IGNORE");
+     …
+
+The other way round does not work.
+
+     …
+     arp.setProperty("IGN_DAML_COLLECTION","EM_IGNORE");
+     arp.setProperty("error-mode", "strict" );
+     …
+
+This is because in strict mode
+[`IGN_DAML_COLLECTION`](/documentation/javadoc/jena/org/apache/jena/rdfxml0/xmlinput/ARPErrorNumbers.html#IGN_DAML_COLLECTION)
+is treated as an error, and so the second call to `setProperty`
+overwrites the effect of the first.
+
+The IRI rules and resolver can be set on a per-reader basis:
+
+    InputStream in = ... ;
+    String baseURI = ... ;
+    Model model = ModelFactory.createDefaultModel();
+    RDFReader r = model.getReader("RDF/XML");
+    r.setProperty("iri-rules", "strict") ;
+    r.setProperty("error-mode", "strict") ; // Warning will be errors.
+
+    // Alternative to the above "error-mode": set specific warning to be an error.
+    //r.setProperty( "WARN_MALFORMED_URI", ARPErrorNumbers.EM_ERROR) ;
+    r.read(model, in, baseURI) ;
+    in.close();
+
+The global default IRI engine can be set with:
+
+    ARPOptions.setIRIFactoryGlobal(IRIFactory.iriImplementation()) ;
+
+or other IRI rule engine from `IRIFactory`.
+
+## Further details
+
+[Details of ARP, the Jena RDF/XML parser](arp/arp.html)
diff --git a/source/documentation/io/rdfxml-io.md b/source/documentation/io/rdfxml-io.md
new file mode 100644
index 000000000..8b81c36af
--- /dev/null
+++ b/source/documentation/io/rdfxml-io.md
@@ -0,0 +1,71 @@
+---
+title: Jena RDF XML
+---
+
+This is a guide to the RDF/XML I/O subsystem of Jena.
+
+The RDF/XML parser is designed for use with RIOT and to have the same handling
+of errors, IRI resolution, and treatment of base IRIs as other RIOT readers.
+
+
+## RDF/XML Input
+
+The usual way to access the RDF/XML parser is via `RDFDataMgr` or `RDFParser`.
+
+    Model model = RDFDataMgr.loadModel("data.rdf");
+
+or
+
+    Model model = RDFParser.source("data.rdf").toModel();
+
+The original "ARP" parser is still available bu tmaybe pahsed out.  To access
+the legacy parser, use the context symbol `RIOT.symRDFXML0` to `true` or
+`"true".
+
+    Model model = RDFParser.source(""data.rdf")
+                           .set(RIOT.symRDFXML0, true)
+                           .parse(dest);
+
+This applies to the command line:
+
+    riot --set rdfxml:rdfxml0=true data.rdf
+
+This can be set globally in the JVM:
+
+    RIOT.getContext().set(RIOT.symRDFXML0, "true");
+
+Details of [legacy RDF/XML input](rdfxml-input.html).
+
+Details of the original Jena RDF/XML parser, [ARP](arp/arp.html).
+
+## RDF/XML Output
+
+Two forms for output are provided:
+
+* The default output `Lang.RDFXML`, historically called "RDF/XML-ABBREV", which
+also has a format name `RDFFormat.RDFXML_PRETTY`. It produces readable
+output. It requires working memory to analyse the data to be written and it is
+not streaming.
+
+* For efficient, streaming output, the basic RDF/XML `RDFFormat.RDFXML_PLAIN`
+works for data of any size. It outputs each subject together with all property
+values without using the full features of RDF/XML.
+
+For "RDF/XML-ABBREV":
+
+    RDFDataMgr.write(System.out, model, Lang.RDFXML);
+
+or
+
+    RDFWriter.source(model).lang(Lang.RDFXML).output(System.out);
+
+and for plain RDF/XML:
+
+    RDFDataMgr.write(System.out, model, RDFFormat.RDFXML_PLAIN);
+
+or
+
+    RDFWriter.source(model).format(RDFFormat.RDFXML_PLAIN).output(System.out);
+
+
+Details of [legacy RDF/XML output](rdfxml-output.html).
diff --git a/source/documentation/io/rdfxml-output.md b/source/documentation/io/rdfxml-output.md
new file mode 100644
index 000000000..c17ada0b9
--- /dev/null
+++ b/source/documentation/io/rdfxml-output.md
@@ -0,0 +1,243 @@
+---
+title: Jena RDF/XML Output How-To
+---
+
+_Legacy Documentation : may not be up-to-date_
+
+Original [RDF/XML HowTo](rdfxml_howto.html).
+
+---
+
+## Advanced RDF/XML Output
+
+Two forms for output are provided: pretty printed RDF/XML ("RDF/XML-ABBREV") or plain RDF/XML
+
+While some of the code is shared, these
+two writers are really very different, resulting in different but
+equivalent output. "RDF/XML-ABBREV" is slower, but should produce
+more readable XML.
+
+### Properties to Control RDF/XML Output
+
+<table>
+<tr><th>Property Name</th><th>Description</th><th>Value class</th><th>Legal Values</th></tr>
+<tr>
+<td><tt>xmlbase</tt></td>
+<td>The value to be included for an xml:base attribute on the root element in the file.</td>
+<td><tt>String</tt></td>
+<td>A URI string, or null (default)</td>
+</tr>
+<tr>
+<td><tt>longId</tt></td>
+<td>Whether to use long or short id's for anon resources. Short id's are easier to read and are the default, but can run out of memory on very large models.</td>
+<td><tt>String</tt> or <tt>Boolean</tt></td>
+<td><tt>"true"</tt>, <tt>"false"</tt> (default)</td>
+</tr>
+<tr>
+<td><tt>allowBadURIs</tt></td>
+<td>URIs in the graph are, by default, checked prior to serialization.</td>
+<td><tt>String</tt> or <tt>Boolean</tt></td>
+<td><tt>"true"</tt>, <tt>"false"</tt> (default)</td>
+</tr>
+<tr>
+<td><tt>relativeURIs</tt></td>
+<td>What sort of relative URIs should be used. A comma separated list of options:
+
+- *same-document*<br />
+ same-document references (e.g. "" or "\#foo")
+- *network*<br />
+  network paths e.g. `"//example.org/foo"` omitting the URI scheme
+- *absolute*<br />
+  absolute paths e.g. `"/foo"` omitting the scheme and authority
+- *relative*<br />
+  relative path not beginning in `"../"`
+- *parent*<br />
+  relative path beginning in `"../"`
+- *grandparent*<br />
+  relative path beginning in `"../../"`
+
+The default value is "same-document, absolute, relative, parent".
+To switch off relative URIs use the value "". Relative URIs of any
+of these types are output where possible if and only if the option
+has been specified.</td>
+<td>String</td>
+<td>&nbsp;</td>
+</tr>
+<tr>
+<td><tt>showXmlDeclaration</tt></td>
+<td>
+If true, an XML Declaration is included in the output, if false no XML declaration is included.
+The default behaviour only gives an XML Declaration when asked to write to an `OutputStreamWriter`
+that uses some encoding other than UTF-8 or UTF-16. In this case the encoding is shown in the
+XML declaration. To ensure that the encoding attribute is shown in the XML declaration either:
+
+- Set this option to true and use the
+    `write(Model,Writer,String)` variant with an appropriate `OutputStreamWriter`.
+- Or set this option to false, and write the declaration to an `OutputStream` before calling
+    `write(Model,OutputStream,String)`.
+</td>
+<td><tt>true</tt>, <tt>"true"</tt>, <tt>false</tt>, <tt>"false"</tt> or <tt>"default"</tt></td>
+<td>can be true, false or "default" (null)</td>
+</tr>
+<tr>
+<td><tt>showDoctypeDeclaration</tt></td>
+<td>
+If true, an XML Doctype declaration is included in the output. This
+declaration includes a `!ENTITY` declaration for each prefix mapping
+in the model, and any attribute value that starts with the URI of
+that mapping is written as starting with the corresponding entity
+invocation.
+</td>
+<td><tt>String</tt> or <tt>Boolean</tt></td>
+<td><tt>true</tt>, <tt>false</tt>, <tt>"true"</tt>, <tt>"false"</tt></td>
+</tr>
+<tr>
+<td><tt>tab</tt></td>
+<td>The number of spaces with which to indent XML child elements.</td>
+<td><tt>String</tt> or <tt>Integer</tt></td>
+<td>positive integer "2" is the default</td>
+</tr>
+<tr>
+<td><tt>attributeQuoteChar</tt></td>
+<td>How to write XML attributes.</td>
+<td><tt>String</tt></td>
+<td><tt>"\""</tt> or <tt>"'"</tt></td>
+</tr>
+<tr>
+<td><tt>blockRules</tt></td>
+<td>
+A list of `Resource` or a `String` being a comma separated list of
+fragment IDs from [http://www.w3.org/TR/rdf-syntax-grammar](http://www.w3.org/TR/rdf-syntax-grammar)
+indicating grammar rules that will not be used. Rules that can be blocked are:
+
+- [section-Reification](http://www.w3.org/TR/rdf-syntax-grammar#section-Reification)
+ ([`RDFSyntax.sectionReification`](/documentation/javadoc/jena/org/apache/jena/vocabulary/RDFSyntax.html#sectionReification))
+- [section-List-Expand](http://www.w3.org/TR/rdf-syntax-grammar#section-List-Expand)
+ ([`RDFSyntax.sectionListExpand`](/documentation/javadoc/jena/org/apache/jena/vocabulary/RDFSyntax.html#sectionListExpand))
+- [parseTypeLiteralPropertyElt](http://www.w3.org/TR/rdf-syntax-grammar#parseTypeLiteralPropertyElt)
+ ([`RDFSyntax.parseTypeLiteralPropertyElt`](/documentation/javadoc/jena/org/apache/jena/vocabulary/RDFSyntax.html#parseTypeLiteralPropertyElt))
+- [parseTypeResourcePropertyElt](http://www.w3.org/TR/rdf-syntax-grammar#parseTypeResourcePropertyElt)
+ ([`RDFSyntax.parseTypeLiteralPropertyElt`](/documentation/javadoc/jena/org/apache/jena/vocabulary/RDFSyntax.html#parseTypeLiteralPropertyElt))
+- [parseTypeCollectionPropertyElt](http://www.w3.org/TR/rdf-syntax-grammar#parseTypeCollectionPropertyElt)
+ ([`RDFSyntax.parseTypeCollectionPropertyElt`](/documentation/javadoc/jena/org/apache/jena/vocabulary/RDFSyntax.html#parseTypeCollectionPropertyElt))
+- [idAttr](http://www.w3.org/TR/rdf-syntax-grammar#idAttr)
+ ([`RDFSyntax.idAttr`](/documentation/javadoc/jena/org/apache/jena/vocabulary/RDFSyntax.html#idAttr))
+- [propertyAttr](http://www.w3.org/TR/rdf-syntax-grammar#propertyAttr)
+ ([`RDFSyntax.propertyAttr`](/documentation/javadoc/jena/org/apache/jena/vocabulary/RDFSyntax.html#propertyAttr))
+
+In addition `"daml:collection"`
+([`DAML_OIL.collection`](/documentation/javadoc/jena/org/apache/jena/vocabulary/DAML_OIL.html#collection))
+can be blocked. Blocking
+[idAttr](http://www.w3.org/TR/rdf-syntax-grammar#idAttr) also
+blocks
+[section-Reification](http://www.w3.org/TR/rdf-syntax-grammar#section-Reification).
+By default, rule
+[propertyAttr](http://www.w3.org/TR/rdf-syntax-grammar#propertyAttr)
+is blocked. For the basic writer (RDF/XML) only
+[parseTypeLiteralPropertyElt](http://www.w3.org/TR/rdf-syntax-grammar#parseTypeLiteralPropertyElt)
+has any effect, since none of the other rules are implemented by
+that writer.
+</td>
+<td><tt>Resource[]</tt> or <tt>String</tt></td>
+<td></td>
+</tr>
+<tr> 
+<td><tt>prettyTypes</tt></td>
+<td>
+Only for the RDF/XML-ABBREV writer. This is a list of the types of
+the principal objects in the model. The writer will tend to create
+RDF/XML with resources of these types at the top level.
+</td>
+<td>
+<tt>Resource[]</tt>
+</td>
+<td></td>
+</tr>
+</table>
+
+To set properties on the RDF/XML writer:
+
+```
+    // Properties to be set.
+    Map<String, Object> properties = new HashMap<>() ;
+    properties.put("showXmlDeclaration", "true");
+
+     RDFWriter.create()
+        .base("http://example.org/")
+        .format(RDFFormat.RDFXML_PLAIN)
+        .set(SysRIOT.sysRdfWriterProperties, properties)
+        .source(model)
+        .output(System.out);
+```
+
+See
+[ExRIOT_RDFXML_WriterProperties.java](https://github.com/apache/jena/blob/main/jena-examples/src/main/java/arq/examples/riot/ExRIOT_RDFXML_WriterProperties.java).
+
+<b>Legacy example</b>
+
+As an example,
+
+    RDFWriter w = m.getWriter("RDF/XML-ABBREV");
+    w.setProperty("attributeQuoteChar","'");
+    w.setProperty("showXMLDeclaration","true");
+    w.setProperty("tab","1");
+    w.setProperty("blockRules",
+      "daml:collection,parseTypeLiteralPropertyElt,"
+      +"parseTypeResourcePropertyElt,parseTypeCollectionPropertyElt");
+
+creates a writer that does not use rdf:parseType (preferring
+rdf:datatype for rdf:XMLLiteral), indents only a little, and
+produces the XMLDeclaration. Attributes are used, and are quoted
+with `"'"`.
+
+Note that property attributes are not used at all, by default.
+However, the RDF/XML-ABBREV writer includes a rule to produce
+property attributes when the value does not contain any spaces.
+This rule is normally switched off. This rule can be turned on
+selectively by using the blockRules property as detailed above.
+
+## Conformance
+
+The RDF/XML I/O endeavours to conform with the
+[RDF Syntax Recommendation](http://www.w3.org/TR/rdf-syntax-grammar/).
+
+The parser must be set to strict mode. (Note that, the conformant
+behaviour for `rdf:parseType="daml:collection"` is to silently turn
+`"daml:collection"` into `"Literal"`).
+
+The RDF/XML writer is conformant, but does not exercise much of the
+grammar.
+
+The RDF/XML-ABBREV writer exercises all of the grammar and is
+conformant except that it uses the `daml:collection` construct for
+DAML ontologies. This non-conformant behaviour can be switched off
+using the `blockRules` property.
+
+## Faster RDF/XML I/O
+
+To optimise the speed of writing RDF/XML it is suggested that all
+URI processing is turned off. Also do not use RDF/XML-ABBREV. It is
+unclear whether the longId attribute is faster or slower; the short
+IDs have to be generated on the fly and a table maintained during
+writing. The longer IDs are long, and hence take longer to write.
+The following creates a faster writer:
+
+    Model m;
+    …
+    …
+    RDFWriter fasterWriter = m.getWriter("RDF/XML");
+    fasterWriter.setProperty("allowBadURIs","true");
+    fasterWriter.setProperty("relativeURIs","");
+    fasterWriter.setProperty("tab","0");
+
+When reading RDF/XML the check for reuse of rdf:ID has a memory
+overhead, which can be significant for very large files. In this
+case, this check can be suppressed by telling ARP to ignore this
+error.
+
+    Model m;
+    …
+    …
+    RDFReader bigFileReader = m.getReader("RDF/XML");
+    bigFileReader.setProperty("WARN_REDEFINITION_OF_ID","EM_IGNORE");
+    …
diff --git a/source/documentation/io/rdfxml_howto.md b/source/documentation/io/rdfxml_howto.md
index 956a05561..01c4a58b9 100644
--- a/source/documentation/io/rdfxml_howto.md
+++ b/source/documentation/io/rdfxml_howto.md
@@ -2,6 +2,10 @@
 title: Jena RDF/XML How-To
 ---
 
+_Legacy Documentation : may not be up-to-date_
+
+---
+
 This is a guide to the RDF/XML I/O subsystem of Jena, ARP.
 The first section gives a quick introduction to the
 I/O subsystem. The other sections are aimed at users wishing to use


[jena-site] 01/02: Formatting

Posted by an...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

andy pushed a commit to branch rdfxml
in repository https://gitbox.apache.org/repos/asf/jena-site.git

commit f30ee7170673c9b52412a0b0813d92971adae53b
Author: Andy Seaborne <an...@apache.org>
AuthorDate: Tue Mar 21 20:27:25 2023 +0000

    Formatting
---
 source/documentation/fuseki2/fuseki-configuration.md | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/source/documentation/fuseki2/fuseki-configuration.md b/source/documentation/fuseki2/fuseki-configuration.md
index 8f33b5291..8e1b23ff8 100644
--- a/source/documentation/fuseki2/fuseki-configuration.md
+++ b/source/documentation/fuseki2/fuseki-configuration.md
@@ -150,7 +150,7 @@ graph of data.
 
 The standard SPARQL operations can also be defined on the dataset URL with no secondary service name:
 
-<#service2> rdf:type fuseki:Service ;
+    <#service2> rdf:type fuseki:Service ;
         fuseki:name     "/dataset" ;
         fuseki:endpoint  [ fuseki:operation fuseki:query ];
         fuseki:endpoint  [ fuseki:operation fuseki:gsp_r ];