public final class ParserOptions extends Object
Options for RDF parsing
.
Modifier and Type | Field and Description |
---|---|
static Option<String> |
BASE_IRI |
static Option<Boolean> |
CASE_INSENSITIVE_DIRECTIVES |
static Option<Boolean> |
FAIL_ON_DUPLICATE_RDF_ID
Parser setting to determine whether to throw an error for duplicate uses of rdf:ID in a single
document.
|
static Option<Boolean> |
FAIL_ON_INVALID_LINES |
static Option<Boolean> |
FAIL_ON_INVALID_NCNAME
Parser setting to determine whether to ignore XML documents containing invalid NCNAMEs.
|
static Option<Boolean> |
FAIL_ON_INVALID_QNAME
Parser setting to determine whether to ignore XML documents containing invalid QNAMEs.
|
static Option<Boolean> |
FAIL_ON_MISMATCHED_TAGS
Parser setting to determine whether to throw an error for XML documents containing mismatched tags
|
static Option<Boolean> |
FAIL_ON_NON_STANDARD_ATTRIBUTES
Parser setting to determine whether to ignore non-standard attributes that are found in an XML
document.
|
static Option<Boolean> |
FAIL_ON_SAX_NON_FATAL_ERRORS
Parser setting to determine whether to ignore non-fatal errors that come from SAX parsers.
|
static Option<LanguageHandler> |
LANG_HANDLER
Lnaguage handler that will be used for verification and normalization.
|
static Option<Boolean> |
LOAD_EXTERNAL_DTD
Parser setting specifying whether external DTDs should be loaded.
|
static Option<Iterable<Namespace>> |
NAMESPACES |
static Option<Boolean> |
NORMALIZE_DATATYPES |
static Option<Boolean> |
NORMALIZE_LANG |
static Option<Boolean> |
PRESERVE_BNODE_IDS
This option controls if the parser should preserve bnode identifiers specified in the source.
|
static Option<Boolean> |
SECURE_PROCESSING
Parser setting for the secure processing feature of XML parsers to avoid DOS attacks
|
static Option<Boolean> |
VERIFY_DATATYPES |
static Option<Boolean> |
VERIFY_IRI_SYNTAX |
static Option<Boolean> |
VERIFY_LANG |
static Option<Boolean> |
VERIFY_RELATIVE_IRIS |
Modifier and Type | Method and Description |
---|---|
static Options |
baseIRI(String theIRI)
Return the default options with the
base IRI set to the given value |
static Options |
defaults()
Default parser options
|
static Options |
lax()
Return a set of `Options` which correspond to default settings for a strict RDF parsing mode
|
static Options |
namespaces(Iterable<Namespace> theNamespaces)
Return the default options with
namespaces set to the given value |
static Options |
strict()
Return a set of `Options` which correspond to default settings for a strict RDF parsing mode
|
public static final Option<LanguageHandler> LANG_HANDLER
public static final Option<Boolean> PRESERVE_BNODE_IDS
This option controls if the parser should preserve bnode identifiers specified in the source. Preserving bnode identifiers help speed parsing and loading time but it also has an important side-effect that if two distinct files using the same bnode identifier are loaded to the same database, the bnode in different files will end up pointing to the same node in the database. If the input files do not use bnode identifiers (e.g. in Turtle syntax only [] are used for bnodes) then this configuration option has no effect since such bnodes are always assigned a unique identifier. But if input files use explicit bnode identifiers (e.g. _:bnode1 in Turtle syntax) and multiple files may use same bnode identifiers then this configuration option should be turned off.
public static final Option<Boolean> SECURE_PROCESSING
Defaults to true
public static final Option<Boolean> LOAD_EXTERNAL_DTD
Defaults to true.
public static final Option<Boolean> FAIL_ON_SAX_NON_FATAL_ERRORS
Defaults to true
public static final Option<Boolean> FAIL_ON_NON_STANDARD_ATTRIBUTES
Defaults to true
public static final Option<Boolean> FAIL_ON_INVALID_NCNAME
Defaults to true
public static final Option<Boolean> FAIL_ON_DUPLICATE_RDF_ID
Defaults to true
public static final Option<Boolean> FAIL_ON_INVALID_QNAME
Defaults to true
@Nonnull public static Options defaults()
@Nonnull public static Options namespaces(@Nonnull Iterable<Namespace> theNamespaces)
namespaces
set to the given valuetheNamespaces
- the namespaces@Nonnull public static Options baseIRI(@Nonnull String theIRI)
base IRI
set to the given valuetheIRI
- the base IRI@Nonnull public static Options strict()
Copyright © 2010-2016 Stardog Union. All Rights Reserved.