RDFParser
Obtains data from an RDFReader
The approach is similar to parser combinators but instead of sequence of characters, we have RDF graphs available through an RDFReader
Type members
Types
Value members
Concrete methods
Applies a list of parsers If a parser fails, it continues with the rest of the list
Applies a list of parsers If a parser fails, it continues with the rest of the list
- Returns:
the list of successful values that can be parsed
Applies a list of parsers
Applies a list of parsers
- Value parameters:
- ps:
List of parsers. Each parser returns a list of values
Returns the Decimal literal associated with a predicate p
Returns the Decimal literal associated with a predicate p
- Value parameters:
- p
predicate
- Returns:
An RDFParser that returns the decimal literal associated with that predicate
If a parser fails, it continues with the rest of the list
If a parser fails, it continues with the rest of the list
- Returns:
the result of the first parser that succeeds of failure
Applies a parser over a sequence of nodes
Applies a parser over a sequence of nodes
- Value parameters:
- nodes
sequence of nodes
- parser
parser
Returns true
if the current node does not have a given type
Returns true
if the current node does not have a given type
- Value parameters:
- t
type to be checked
Returns true
if the current node has a given type
Returns true
if the current node has a given type
- Value parameters:
- t
type to be checked
Returns true
if the current node has a type which belong to a given set of types
Returns true
if the current node has a type which belong to a given set of types
- Value parameters:
- ts
set of types to be checked
Obtains an integer literal associated with a predicate in the current node
Obtains an integer literal associated with a predicate in the current node
- Value parameters:
- p
predicate
Parses a list of values. The list must contain at least one value
Parses a list of values. The list must contain at least one value
Parses a list of values. The list must contain at least two values
Parses a list of values. The list must contain at least two values
RDFParser that retrieves the object associated with current node for a given predicate
RDFParser that retrieves the object associated with current node for a given predicate
Fails if there are more than one object
- Value parameters:
- p
predicate
RDFParser that retrieves the set of iriObjects associated with the current node for a given predicate
RDFParser that retrieves the set of iriObjects associated with the current node for a given predicate
- Value parameters:
- p
predicate
Checks that exactly one of the parsers succeeds on the current node
Checks that exactly one of the parsers succeeds on the current node
- Value parameters:
- parsers
sequence of parsers
An RDF parser that parses a value of type a
if possible
An RDF parser that parses a value of type a
if possible
A parser of the RDF List associated with the current node
A parser of the RDF List associated with the current node
Fails if there are more than one iriObjects associated with rdf_first
or rdf_rest
Obtains the RDF list associated with a predicate for the current node
Obtains the RDF list associated with a predicate for the current node
- Value parameters:
- p
predicate
Obtains the RDF list associated with a predicate for the current node If there is no value, returns the empty list
Obtains the RDF list associated with a predicate for the current node If there is no value, returns the empty list
- Value parameters:
- p
predicate
Returns a parser that obtains the type associated with the current node
Returns a parser that obtains the type associated with the current node
Fails if there are more than one type associated
Returns a parser that obtains the set of types associated with the current node
Returns a parser that obtains the set of types associated with the current node
Checks if some of the parsers pass and returns the corresponding value
Checks if some of the parsers pass and returns the corresponding value
- Value parameters:
- ps
sequence of parsers