You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@marmotta.apache.org by ss...@apache.org on 2013/09/30 18:44:43 UTC
[06/50] [abbrv] git commit: renamed RdfPathParser to LdPathParser
renamed RdfPathParser to LdPathParser
Project: http://git-wip-us.apache.org/repos/asf/incubator-marmotta/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-marmotta/commit/6591259a
Tree: http://git-wip-us.apache.org/repos/asf/incubator-marmotta/tree/6591259a
Diff: http://git-wip-us.apache.org/repos/asf/incubator-marmotta/diff/6591259a
Branch: refs/heads/master
Commit: 6591259a44ba5ec66f71ef1c8ac47791a5d43d29
Parents: 55e05ef
Author: Jakob Frank <ja...@apache.org>
Authored: Mon Sep 9 15:57:12 2013 +0200
Committer: Jakob Frank <ja...@apache.org>
Committed: Tue Sep 10 12:30:34 2013 +0200
----------------------------------------------------------------------
.../ldpath/backend/file/ParserTest.java | 6 ++--
.../java/org/apache/marmotta/ldpath/LDPath.java | 12 ++++----
.../at/newmedialab/ldpath/parser/rdfpath.jj | 22 +++++++-------
.../BinaryNumericTestFunctionsTest.java | 4 +--
.../ldpath/model/functions/FunctionsTest.java | 16 +++++------
.../marmotta/ldpath/parser/ParserTest.java | 10 +++----
.../marmotta/ldpath/parser/ProgramTest.java | 2 +-
.../marmotta/ldpath/parser/SelectorsTest.java | 2 +-
.../marmotta/ldpath/parser/TestsTest.java | 2 +-
.../marmotta/ldpath/test/AbstractTestBase.java | 14 ++++-----
.../model/functions/date/DateFunctionsTest.java | 6 ++--
.../model/functions/html/HtmlFunctionsTest.java | 8 +++---
.../model/functions/math/MathFunctionTest.java | 30 ++++++++++----------
.../tests/functions/text/StringTestTest.java | 4 +--
.../xml/RemoveXmlTagsFunctionTest.java | 4 +--
.../model/functions/xml/XPathFunctionTest.java | 4 +--
16 files changed, 73 insertions(+), 73 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/incubator-marmotta/blob/6591259a/libraries/ldpath/ldpath-backend-file/src/test/java/org/apache/marmotta/ldpath/backend/file/ParserTest.java
----------------------------------------------------------------------
diff --git a/libraries/ldpath/ldpath-backend-file/src/test/java/org/apache/marmotta/ldpath/backend/file/ParserTest.java b/libraries/ldpath/ldpath-backend-file/src/test/java/org/apache/marmotta/ldpath/backend/file/ParserTest.java
index 6872c4c..11d96f5 100644
--- a/libraries/ldpath/ldpath-backend-file/src/test/java/org/apache/marmotta/ldpath/backend/file/ParserTest.java
+++ b/libraries/ldpath/ldpath-backend-file/src/test/java/org/apache/marmotta/ldpath/backend/file/ParserTest.java
@@ -30,7 +30,7 @@ import org.apache.marmotta.ldpath.model.selectors.TestingSelector;
import org.apache.marmotta.ldpath.model.selectors.UnionSelector;
import org.apache.marmotta.ldpath.model.transformers.StringTransformer;
import org.apache.marmotta.ldpath.parser.ParseException;
-import org.apache.marmotta.ldpath.parser.RdfPathParser;
+import org.apache.marmotta.ldpath.parser.LdPathParser;
import org.hamcrest.CoreMatchers;
import org.junit.Assert;
import org.junit.BeforeClass;
@@ -83,7 +83,7 @@ public class ParserTest {
}
private NodeSelector<Value> parseSelector(String selector, Map<String,String> namespaces) throws ParseException {
- return new RdfPathParser<Value>(backend,new StringReader(selector)).parseSelector(namespaces);
+ return new LdPathParser<Value>(backend,new StringReader(selector)).parseSelector(namespaces);
}
@Test
@@ -114,7 +114,7 @@ public class ParserTest {
}
private Program<Value> parseProgram(String selector) throws ParseException {
- return new RdfPathParser<Value>(backend,new StringReader(selector)).parseProgram();
+ return new LdPathParser<Value>(backend,new StringReader(selector)).parseProgram();
}
http://git-wip-us.apache.org/repos/asf/incubator-marmotta/blob/6591259a/libraries/ldpath/ldpath-core/src/main/java/org/apache/marmotta/ldpath/LDPath.java
----------------------------------------------------------------------
diff --git a/libraries/ldpath/ldpath-core/src/main/java/org/apache/marmotta/ldpath/LDPath.java b/libraries/ldpath/ldpath-core/src/main/java/org/apache/marmotta/ldpath/LDPath.java
index bc46c41..29cf999 100644
--- a/libraries/ldpath/ldpath-core/src/main/java/org/apache/marmotta/ldpath/LDPath.java
+++ b/libraries/ldpath/ldpath-core/src/main/java/org/apache/marmotta/ldpath/LDPath.java
@@ -36,7 +36,7 @@ import org.apache.marmotta.ldpath.model.programs.Program;
import org.apache.marmotta.ldpath.parser.Configuration;
import org.apache.marmotta.ldpath.parser.DefaultConfiguration;
import org.apache.marmotta.ldpath.parser.ParseException;
-import org.apache.marmotta.ldpath.parser.RdfPathParser;
+import org.apache.marmotta.ldpath.parser.LdPathParser;
import com.google.common.collect.ImmutableList;
import com.google.common.collect.ImmutableMap;
@@ -104,7 +104,7 @@ public class LDPath<Node> {
* @throws LDPathParseException when the path passed as argument is not valid
*/
public Collection<Node> pathQuery(Node context, String path, Map<String, String> namespaces) throws LDPathParseException {
- RdfPathParser<Node> parser = new RdfPathParser<Node>(backend,config,new StringReader(path));
+ LdPathParser<Node> parser = new LdPathParser<Node>(backend,config,new StringReader(path));
for(SelectorFunction<Node> function : functions) {
parser.registerFunction(function);
}
@@ -150,7 +150,7 @@ public class LDPath<Node> {
* @throws LDPathParseException when the path passed as argument is not valid
*/
public Collection<Node> pathQuery(Node context, String path, Map<String, String> namespaces, Map<Node,List<Node>> paths) throws LDPathParseException {
- RdfPathParser<Node> parser = new RdfPathParser<Node>(backend,config,new StringReader(path));
+ LdPathParser<Node> parser = new LdPathParser<Node>(backend,config,new StringReader(path));
for(SelectorFunction<Node> function : functions) {
parser.registerFunction(function);
}
@@ -194,7 +194,7 @@ public class LDPath<Node> {
* @throws LDPathParseException when the path passed as argument is not valid
*/
public <T> Collection<T> pathTransform(Node context, String path, Map<String, String> namespaces) throws LDPathParseException {
- RdfPathParser<Node> parser = new RdfPathParser<Node>(backend,config,new StringReader(path));
+ LdPathParser<Node> parser = new LdPathParser<Node>(backend,config,new StringReader(path));
for(SelectorFunction<Node> function : functions) {
parser.registerFunction(function);
}
@@ -223,7 +223,7 @@ public class LDPath<Node> {
* @throws LDPathParseException
*/
public Map<String,Collection<?>> programQuery(Node context, Reader program) throws LDPathParseException {
- RdfPathParser<Node> parser = new RdfPathParser<Node>(backend,config,program);
+ LdPathParser<Node> parser = new LdPathParser<Node>(backend,config,program);
for(SelectorFunction<Node> function : functions) {
parser.registerFunction(function);
}
@@ -255,7 +255,7 @@ public class LDPath<Node> {
* @throws LDPathParseException
*/
public Program<Node> parseProgram(Reader program) throws LDPathParseException {
- RdfPathParser<Node> parser = new RdfPathParser<Node>(backend,config,program);
+ LdPathParser<Node> parser = new LdPathParser<Node>(backend,config,program);
for(SelectorFunction<Node> function : functions) {
parser.registerFunction(function);
}
http://git-wip-us.apache.org/repos/asf/incubator-marmotta/blob/6591259a/libraries/ldpath/ldpath-core/src/main/javacc/at/newmedialab/ldpath/parser/rdfpath.jj
----------------------------------------------------------------------
diff --git a/libraries/ldpath/ldpath-core/src/main/javacc/at/newmedialab/ldpath/parser/rdfpath.jj b/libraries/ldpath/ldpath-core/src/main/javacc/at/newmedialab/ldpath/parser/rdfpath.jj
index 0fd1c44..bd0e133 100644
--- a/libraries/ldpath/ldpath-core/src/main/javacc/at/newmedialab/ldpath/parser/rdfpath.jj
+++ b/libraries/ldpath/ldpath-core/src/main/javacc/at/newmedialab/ldpath/parser/rdfpath.jj
@@ -26,7 +26,7 @@ options
// DEBUG_LOOKAHEAD=true;
}
-PARSER_BEGIN(RdfPathParser)
+PARSER_BEGIN(LdPathParser)
package org.apache.marmotta.ldpath.parser;
import org.apache.marmotta.ldpath.model.Constants;
@@ -65,12 +65,12 @@ import org.slf4j.LoggerFactory;
@SuppressWarnings("all")
-public class RdfPathParser<Node> {
+public class LdPathParser<Node> {
private enum Mode { RULE, SELECTOR, TEST, PROGRAM, PREFIX };
- private static final Logger log = LoggerFactory.getLogger(RdfPathParser.class);
+ private static final Logger log = LoggerFactory.getLogger(LdPathParser.class);
/**
* A map mapping from namespace prefix to namespace URI
@@ -83,11 +83,11 @@ public class RdfPathParser<Node> {
private Mode mode = Mode.PROGRAM;
- public RdfPathParser(NodeBackend<Node> backend, Reader in) {
+ public LdPathParser(NodeBackend<Node> backend, Reader in) {
this(backend,null,in);
}
- public RdfPathParser(NodeBackend<Node> backend, Configuration config, Reader in) {
+ public LdPathParser(NodeBackend<Node> backend, Configuration config, Reader in) {
this(in);
this.backend = backend;
if(config == null) {
@@ -99,11 +99,11 @@ public class RdfPathParser<Node> {
initialise();
}
- public RdfPathParser(NodeBackend<Node> backend, InputStream in) {
+ public LdPathParser(NodeBackend<Node> backend, InputStream in) {
this(backend,null,in);
}
- public RdfPathParser(NodeBackend<Node> backend, Configuration config, InputStream in) {
+ public LdPathParser(NodeBackend<Node> backend, Configuration config, InputStream in) {
this(in);
this.backend = backend;
if(config == null) {
@@ -115,11 +115,11 @@ public class RdfPathParser<Node> {
initialise();
}
- public RdfPathParser(NodeBackend<Node> backend, InputStream in, String encoding) {
+ public LdPathParser(NodeBackend<Node> backend, InputStream in, String encoding) {
this(backend,null,in,encoding);
}
- public RdfPathParser(NodeBackend<Node> backend, Configuration config, InputStream in, String encoding) {
+ public LdPathParser(NodeBackend<Node> backend, Configuration config, InputStream in, String encoding) {
this(in,encoding);
this.backend = backend;
if(config == null) {
@@ -290,7 +290,7 @@ public class RdfPathParser<Node> {
private Map<String, SelectorFunction<Node>> xsdNodeFunctionMap;
- private Map<String, TestFunction<Node>> xsdNodeTestMap;
+ private Map<String, TestFunction<Node>> xsdNodeTestMap;
private void initFunctionMappings() {
Map<String, SelectorFunction<Node>> functionMap = new HashMap<String, SelectorFunction<Node>>();
@@ -334,7 +334,7 @@ public class RdfPathParser<Node> {
}
}
-PARSER_END(RdfPathParser)
+PARSER_END(LdPathParser)
SKIP :
{
http://git-wip-us.apache.org/repos/asf/incubator-marmotta/blob/6591259a/libraries/ldpath/ldpath-core/src/test/java/org/apache/marmotta/ldpath/model/functions/BinaryNumericTestFunctionsTest.java
----------------------------------------------------------------------
diff --git a/libraries/ldpath/ldpath-core/src/test/java/org/apache/marmotta/ldpath/model/functions/BinaryNumericTestFunctionsTest.java b/libraries/ldpath/ldpath-core/src/test/java/org/apache/marmotta/ldpath/model/functions/BinaryNumericTestFunctionsTest.java
index b471e30..948d5c4 100644
--- a/libraries/ldpath/ldpath-core/src/test/java/org/apache/marmotta/ldpath/model/functions/BinaryNumericTestFunctionsTest.java
+++ b/libraries/ldpath/ldpath-core/src/test/java/org/apache/marmotta/ldpath/model/functions/BinaryNumericTestFunctionsTest.java
@@ -29,7 +29,7 @@ import java.util.List;
import org.apache.marmotta.ldpath.api.selectors.NodeSelector;
import org.apache.marmotta.ldpath.parser.ParseException;
-import org.apache.marmotta.ldpath.parser.RdfPathParser;
+import org.apache.marmotta.ldpath.parser.LdPathParser;
import org.apache.marmotta.ldpath.test.AbstractTestBase;
import org.junit.Before;
import org.junit.Test;
@@ -96,7 +96,7 @@ public class BinaryNumericTestFunctionsTest extends AbstractTestBase {
}
- final RdfPathParser<Value> parser = createParserFromString("ex:hasItem[" + fkt + "(foo:left, foo:right)]");
+ final LdPathParser<Value> parser = createParserFromString("ex:hasItem[" + fkt + "(foo:left, foo:right)]");
final NodeSelector<Value> sel = parser.parseSelector(NSS);
final Collection<Value> result = sel.select(backend, start, null, null);
http://git-wip-us.apache.org/repos/asf/incubator-marmotta/blob/6591259a/libraries/ldpath/ldpath-core/src/test/java/org/apache/marmotta/ldpath/model/functions/FunctionsTest.java
----------------------------------------------------------------------
diff --git a/libraries/ldpath/ldpath-core/src/test/java/org/apache/marmotta/ldpath/model/functions/FunctionsTest.java b/libraries/ldpath/ldpath-core/src/test/java/org/apache/marmotta/ldpath/model/functions/FunctionsTest.java
index 8caced2..7df1621 100644
--- a/libraries/ldpath/ldpath-core/src/test/java/org/apache/marmotta/ldpath/model/functions/FunctionsTest.java
+++ b/libraries/ldpath/ldpath-core/src/test/java/org/apache/marmotta/ldpath/model/functions/FunctionsTest.java
@@ -29,7 +29,7 @@ import java.util.Collection;
import org.apache.marmotta.ldpath.api.selectors.NodeSelector;
import org.apache.marmotta.ldpath.model.fields.FieldMapping;
import org.apache.marmotta.ldpath.parser.ParseException;
-import org.apache.marmotta.ldpath.parser.RdfPathParser;
+import org.apache.marmotta.ldpath.parser.LdPathParser;
import org.apache.marmotta.ldpath.test.AbstractTestBase;
import org.hamcrest.CoreMatchers;
import org.junit.Before;
@@ -53,7 +53,7 @@ public class FunctionsTest extends AbstractTestBase {
@Test
public void testConcat() throws ParseException {
- RdfPathParser<Value> parser = createParserFromString("fn:concat(foo:title, \" \", foo:subtitle) :: xsd:string; ");
+ LdPathParser<Value> parser = createParserFromString("fn:concat(foo:title, \" \", foo:subtitle) :: xsd:string; ");
final URI context = repository.getValueFactory().createURI("http://www.example.com/1");
final FieldMapping<Object, Value> field = parser.parseRule(NSS);
@@ -67,7 +67,7 @@ public class FunctionsTest extends AbstractTestBase {
final URI ctx1 = repository.getValueFactory().createURI("http://www.example.com/1");
final URI ctx2 = repository.getValueFactory().createURI("http://www.example.com/2");
- RdfPathParser<Value> parser = createParserFromString("fn:first(foo:not_valid, foo:title, foo:subtitle, foo:not_valid2) :: xsd:string; ");
+ LdPathParser<Value> parser = createParserFromString("fn:first(foo:not_valid, foo:title, foo:subtitle, foo:not_valid2) :: xsd:string; ");
final FieldMapping<Object, Value> field = parser.parseRule(NSS);
final Collection<Object> result = field.getValues(backend, ctx1);
@@ -84,7 +84,7 @@ public class FunctionsTest extends AbstractTestBase {
final URI ctx1 = repository.getValueFactory().createURI("http://www.example.com/1");
final URI ctx2 = repository.getValueFactory().createURI("http://www.example.com/2");
- RdfPathParser<Value> parser = createParserFromString("fn:first(foo:i) :: xsd:int; ");
+ LdPathParser<Value> parser = createParserFromString("fn:first(foo:i) :: xsd:int; ");
final FieldMapping<Object, Value> field = parser.parseRule(NSS);
final Collection<Object> result = field.getValues(backend, ctx1);
@@ -101,7 +101,7 @@ public class FunctionsTest extends AbstractTestBase {
final URI ctx1 = repository.getValueFactory().createURI("http://www.example.com/1");
final URI ctx2 = repository.getValueFactory().createURI("http://www.example.com/2");
- RdfPathParser<Value> parser = createParserFromString("fn:last(foo:not_valid, foo:title, foo:subtitle, foo:not_valid2) :: xsd:string; ");
+ LdPathParser<Value> parser = createParserFromString("fn:last(foo:not_valid, foo:title, foo:subtitle, foo:not_valid2) :: xsd:string; ");
final FieldMapping<Object, Value> field = parser.parseRule(NSS);
final Collection<Object> result = field.getValues(backend, ctx1);
@@ -118,7 +118,7 @@ public class FunctionsTest extends AbstractTestBase {
final URI ctx1 = repository.getValueFactory().createURI("http://www.example.com/1");
final URI ctx2 = repository.getValueFactory().createURI("http://www.example.com/2");
- RdfPathParser<Value> parser = createParserFromString("fn:last(foo:i, ex:not_here) :: xsd:int; ");
+ LdPathParser<Value> parser = createParserFromString("fn:last(foo:i, ex:not_here) :: xsd:int; ");
final FieldMapping<Object, Value> field = parser.parseRule(NSS);
final Collection<Object> result = field.getValues(backend, ctx1);
@@ -136,14 +136,14 @@ public class FunctionsTest extends AbstractTestBase {
final URI ex1 = repository.getValueFactory().createURI("http://www.example.com/1");
final URI ex2 = repository.getValueFactory().createURI("http://www.example.com/2");
- final RdfPathParser<Value> parser = createParserFromString("ex:hasItem[fn:eq(foo:i, foo:j)]");
+ final LdPathParser<Value> parser = createParserFromString("ex:hasItem[fn:eq(foo:i, foo:j)]");
final NodeSelector<Value> sel = parser.parseSelector(NSS);
final Collection<Value> result = sel.select(backend, start, null, null);
assertEquals(1, result.size());
assertThat(result, allOf(hasItem(ex2), not(hasItem(ex1))));
- final RdfPathParser<Value> parseri = createParserFromString("ex:hasItem[! fn:eq(foo:i, foo:j)]");
+ final LdPathParser<Value> parseri = createParserFromString("ex:hasItem[! fn:eq(foo:i, foo:j)]");
final NodeSelector<Value> seli = parseri.parseSelector(NSS);
final Collection<Value> resulti = seli.select(backend, start, null, null);
http://git-wip-us.apache.org/repos/asf/incubator-marmotta/blob/6591259a/libraries/ldpath/ldpath-core/src/test/java/org/apache/marmotta/ldpath/parser/ParserTest.java
----------------------------------------------------------------------
diff --git a/libraries/ldpath/ldpath-core/src/test/java/org/apache/marmotta/ldpath/parser/ParserTest.java b/libraries/ldpath/ldpath-core/src/test/java/org/apache/marmotta/ldpath/parser/ParserTest.java
index 8d2c13f..d7b401a 100644
--- a/libraries/ldpath/ldpath-core/src/test/java/org/apache/marmotta/ldpath/parser/ParserTest.java
+++ b/libraries/ldpath/ldpath-core/src/test/java/org/apache/marmotta/ldpath/parser/ParserTest.java
@@ -66,7 +66,7 @@ public class ParserTest {
@Test
public void testParseProgram() throws IOException {
- RdfPathParser<String> parser = createParser("program.ldpath");
+ LdPathParser<String> parser = createParser("program.ldpath");
try {
Program<String> program = parser.parseProgram();
assertNotNull(program.getField("path"));
@@ -86,7 +86,7 @@ public class ParserTest {
@Test
public void testParseTest() throws IOException {
- RdfPathParser<String> parser = createParser("test.ldpath");
+ LdPathParser<String> parser = createParser("test.ldpath");
try {
NodeTest<String> test = parser.parseTest(NAMESPACES);
assertNotNull(test);
@@ -98,7 +98,7 @@ public class ParserTest {
@Test
public void testParsePrefixes() throws IOException {
- RdfPathParser<String> parser = createParser("namespaces.ldpath");
+ LdPathParser<String> parser = createParser("namespaces.ldpath");
try {
Map<String, String> prefixes = parser.parsePrefixes();
assertTrue(prefixes.containsKey("test"));
@@ -113,11 +113,11 @@ public class ParserTest {
}
- private RdfPathParser<String> createParser(String input) throws IOException {
+ private LdPathParser<String> createParser(String input) throws IOException {
final URL resource = ParserTest.class.getResource("/parse/"+input);
assertThat("Could not load test input data '" + input + "'", resource, CoreMatchers.notNullValue());
- RdfPathParser<String> rdfPathParser = new RdfPathParser<String>(backend,new StringReader(IOUtils.toString(resource)));
+ LdPathParser<String> rdfPathParser = new LdPathParser<String>(backend,new StringReader(IOUtils.toString(resource)));
rdfPathParser.registerTransformer(NS_TEST + "type", new NodeTransformer<String, String>() {
@Override
public String transform(RDFBackend<String> backend, String node, Map<String,String> configuration)
http://git-wip-us.apache.org/repos/asf/incubator-marmotta/blob/6591259a/libraries/ldpath/ldpath-core/src/test/java/org/apache/marmotta/ldpath/parser/ProgramTest.java
----------------------------------------------------------------------
diff --git a/libraries/ldpath/ldpath-core/src/test/java/org/apache/marmotta/ldpath/parser/ProgramTest.java b/libraries/ldpath/ldpath-core/src/test/java/org/apache/marmotta/ldpath/parser/ProgramTest.java
index 0ee7311..ff7e6d1 100644
--- a/libraries/ldpath/ldpath-core/src/test/java/org/apache/marmotta/ldpath/parser/ProgramTest.java
+++ b/libraries/ldpath/ldpath-core/src/test/java/org/apache/marmotta/ldpath/parser/ProgramTest.java
@@ -39,7 +39,7 @@ public class ProgramTest {
expr = IOUtils.toString(resource);
- RdfPathParser<String> rdfPathParser = new RdfPathParser<String>(backend,new StringReader(expr));
+ LdPathParser<String> rdfPathParser = new LdPathParser<String>(backend,new StringReader(expr));
rdfPathParser.registerTransformer("http://example.com/type", new NodeTransformer<String, String>() {
@Override
public String transform(RDFBackend<String> backend, String node, Map<String,String> configuration)
http://git-wip-us.apache.org/repos/asf/incubator-marmotta/blob/6591259a/libraries/ldpath/ldpath-core/src/test/java/org/apache/marmotta/ldpath/parser/SelectorsTest.java
----------------------------------------------------------------------
diff --git a/libraries/ldpath/ldpath-core/src/test/java/org/apache/marmotta/ldpath/parser/SelectorsTest.java b/libraries/ldpath/ldpath-core/src/test/java/org/apache/marmotta/ldpath/parser/SelectorsTest.java
index 321705b..4ac44b5 100644
--- a/libraries/ldpath/ldpath-core/src/test/java/org/apache/marmotta/ldpath/parser/SelectorsTest.java
+++ b/libraries/ldpath/ldpath-core/src/test/java/org/apache/marmotta/ldpath/parser/SelectorsTest.java
@@ -58,7 +58,7 @@ public class SelectorsTest {
@Before
public void before() throws ParseException {
- RdfPathParser<String> rdfPathParser = new RdfPathParser<String>(backend,new StringReader(expr));
+ LdPathParser<String> rdfPathParser = new LdPathParser<String>(backend,new StringReader(expr));
selector = rdfPathParser.parseSelector(Collections.<String,String>emptyMap());
}
http://git-wip-us.apache.org/repos/asf/incubator-marmotta/blob/6591259a/libraries/ldpath/ldpath-core/src/test/java/org/apache/marmotta/ldpath/parser/TestsTest.java
----------------------------------------------------------------------
diff --git a/libraries/ldpath/ldpath-core/src/test/java/org/apache/marmotta/ldpath/parser/TestsTest.java b/libraries/ldpath/ldpath-core/src/test/java/org/apache/marmotta/ldpath/parser/TestsTest.java
index df5410a..1b2ce9d 100644
--- a/libraries/ldpath/ldpath-core/src/test/java/org/apache/marmotta/ldpath/parser/TestsTest.java
+++ b/libraries/ldpath/ldpath-core/src/test/java/org/apache/marmotta/ldpath/parser/TestsTest.java
@@ -53,7 +53,7 @@ public class TestsTest {
@Before
public void before() throws ParseException {
- RdfPathParser<String> rdfPathParser = new RdfPathParser<String>(backend,new StringReader(expr));
+ LdPathParser<String> rdfPathParser = new LdPathParser<String>(backend,new StringReader(expr));
test = rdfPathParser.parseTest(Collections.<String,String>emptyMap());
}
http://git-wip-us.apache.org/repos/asf/incubator-marmotta/blob/6591259a/libraries/ldpath/ldpath-core/src/test/java/org/apache/marmotta/ldpath/test/AbstractTestBase.java
----------------------------------------------------------------------
diff --git a/libraries/ldpath/ldpath-core/src/test/java/org/apache/marmotta/ldpath/test/AbstractTestBase.java b/libraries/ldpath/ldpath-core/src/test/java/org/apache/marmotta/ldpath/test/AbstractTestBase.java
index 2fac58d..e1acd89 100644
--- a/libraries/ldpath/ldpath-core/src/test/java/org/apache/marmotta/ldpath/test/AbstractTestBase.java
+++ b/libraries/ldpath/ldpath-core/src/test/java/org/apache/marmotta/ldpath/test/AbstractTestBase.java
@@ -35,7 +35,7 @@ import org.apache.marmotta.ldpath.api.selectors.NodeSelector;
import org.apache.marmotta.ldpath.backend.sesame.SesameRepositoryBackend;
import org.apache.marmotta.ldpath.model.fields.FieldMapping;
import org.apache.marmotta.ldpath.parser.ParseException;
-import org.apache.marmotta.ldpath.parser.RdfPathParser;
+import org.apache.marmotta.ldpath.parser.LdPathParser;
import org.hamcrest.CoreMatchers;
import org.junit.After;
import org.junit.Assert;
@@ -108,18 +108,18 @@ public abstract class AbstractTestBase {
};
- protected RdfPathParser<Value> createParserFromResource(String input) throws IOException {
+ protected LdPathParser<Value> createParserFromResource(String input) throws IOException {
final URL resource = this.getClass().getResource(input);
assertThat("Could not load test input data '" + input + "'", resource, CoreMatchers.notNullValue());
- RdfPathParser<Value> parser = new RdfPathParser<Value>(backend, resource.openStream());
+ LdPathParser<Value> parser = new LdPathParser<Value>(backend, resource.openStream());
assertThat("Could not parse ldPath", parser, CoreMatchers.notNullValue());
return parser;
}
- protected RdfPathParser<Value> createParserFromString(String program) {
- final RdfPathParser<Value> parser = new RdfPathParser<Value>(backend, new StringReader(program));
+ protected LdPathParser<Value> createParserFromString(String program) {
+ final LdPathParser<Value> parser = new LdPathParser<Value>(backend, new StringReader(program));
assertThat("Could not parse ldPath", parser, CoreMatchers.notNullValue());
return parser;
@@ -146,7 +146,7 @@ public abstract class AbstractTestBase {
}
protected Collection<Object> evaluateRule(final String ldPath, URI context) throws ParseException {
- final RdfPathParser<Value> parser = createParserFromString(ldPath);
+ final LdPathParser<Value> parser = createParserFromString(ldPath);
final FieldMapping<Object, Value> rule = parser.parseRule(NSS);
final Collection<Object> values = rule.getValues(backend, context);
return values;
@@ -166,7 +166,7 @@ public abstract class AbstractTestBase {
}
protected Collection<Value> evaluateSelector(final String ldPath, URI context) throws ParseException {
- final RdfPathParser<Value> parser = createParserFromString(ldPath);
+ final LdPathParser<Value> parser = createParserFromString(ldPath);
final NodeSelector<Value> sel = parser.parseSelector(NSS);
final Collection<Value> nodes = sel.select(backend, context, null, null);
return nodes;
http://git-wip-us.apache.org/repos/asf/incubator-marmotta/blob/6591259a/libraries/ldpath/ldpath-functions-date/src/test/java/org/apache/marmotta/ldpath/model/functions/date/DateFunctionsTest.java
----------------------------------------------------------------------
diff --git a/libraries/ldpath/ldpath-functions-date/src/test/java/org/apache/marmotta/ldpath/model/functions/date/DateFunctionsTest.java b/libraries/ldpath/ldpath-functions-date/src/test/java/org/apache/marmotta/ldpath/model/functions/date/DateFunctionsTest.java
index 69dc472..ea8c9e8 100644
--- a/libraries/ldpath/ldpath-functions-date/src/test/java/org/apache/marmotta/ldpath/model/functions/date/DateFunctionsTest.java
+++ b/libraries/ldpath/ldpath-functions-date/src/test/java/org/apache/marmotta/ldpath/model/functions/date/DateFunctionsTest.java
@@ -24,7 +24,7 @@ import java.util.Random;
import org.apache.marmotta.ldpath.model.fields.FieldMapping;
import org.apache.marmotta.ldpath.parser.ParseException;
-import org.apache.marmotta.ldpath.parser.RdfPathParser;
+import org.apache.marmotta.ldpath.parser.LdPathParser;
import org.apache.marmotta.ldpath.test.AbstractTestBase;
import org.junit.Assert;
import org.junit.Before;
@@ -76,7 +76,7 @@ public class DateFunctionsTest extends AbstractTestBase {
@Test
public void testEarliest() throws ParseException {
- final RdfPathParser<Value> parser = createParserFromString("fn:earliest(<" + prop.stringValue() + ">) :: xsd:dateTime");
+ final LdPathParser<Value> parser = createParserFromString("fn:earliest(<" + prop.stringValue() + ">) :: xsd:dateTime");
final FieldMapping<Object, Value> rule = parser.parseRule(NSS);
final Collection<Object> result = rule.getValues(backend, uri);
@@ -88,7 +88,7 @@ public class DateFunctionsTest extends AbstractTestBase {
@Test
public void testLatest() throws ParseException {
- final RdfPathParser<Value> parser = createParserFromString("fn:latest(<" + prop.stringValue() + ">) :: xsd:dateTime");
+ final LdPathParser<Value> parser = createParserFromString("fn:latest(<" + prop.stringValue() + ">) :: xsd:dateTime");
final FieldMapping<Object, Value> rule = parser.parseRule(NSS);
final Collection<Object> result = rule.getValues(backend, uri);
http://git-wip-us.apache.org/repos/asf/incubator-marmotta/blob/6591259a/libraries/ldpath/ldpath-functions-html/src/test/java/org/apache/marmotta/ldpath/model/functions/html/HtmlFunctionsTest.java
----------------------------------------------------------------------
diff --git a/libraries/ldpath/ldpath-functions-html/src/test/java/org/apache/marmotta/ldpath/model/functions/html/HtmlFunctionsTest.java b/libraries/ldpath/ldpath-functions-html/src/test/java/org/apache/marmotta/ldpath/model/functions/html/HtmlFunctionsTest.java
index d663924..29f5426 100644
--- a/libraries/ldpath/ldpath-functions-html/src/test/java/org/apache/marmotta/ldpath/model/functions/html/HtmlFunctionsTest.java
+++ b/libraries/ldpath/ldpath-functions-html/src/test/java/org/apache/marmotta/ldpath/model/functions/html/HtmlFunctionsTest.java
@@ -27,7 +27,7 @@ import java.util.Collection;
import org.apache.marmotta.ldpath.model.fields.FieldMapping;
import org.apache.marmotta.ldpath.parser.ParseException;
-import org.apache.marmotta.ldpath.parser.RdfPathParser;
+import org.apache.marmotta.ldpath.parser.LdPathParser;
import org.apache.marmotta.ldpath.test.AbstractTestBase;
import org.hamcrest.CoreMatchers;
import org.junit.Before;
@@ -50,7 +50,7 @@ public class HtmlFunctionsTest extends AbstractTestBase {
public void testCleanHtmlFunction() throws ParseException {
URI uri = repository.getValueFactory().createURI(NSS.get("ex") + "Simple");
- final RdfPathParser<Value> parser = createParserFromString("fn:cleanHtml(foo:html) :: xsd:string");
+ final LdPathParser<Value> parser = createParserFromString("fn:cleanHtml(foo:html) :: xsd:string");
final FieldMapping<Object, Value> rule = parser.parseRule(NSS);
final Collection<Object> result = rule.getValues(backend, uri);
@@ -67,7 +67,7 @@ public class HtmlFunctionsTest extends AbstractTestBase {
public void testCssSelectFunction() throws ParseException {
URI uri = repository.getValueFactory().createURI(NSS.get("ex") + "Simple");
- final RdfPathParser<Value> parser = createParserFromString("fn:css(\"p\", foo:html) :: xsd:string");
+ final LdPathParser<Value> parser = createParserFromString("fn:css(\"p\", foo:html) :: xsd:string");
final FieldMapping<Object, Value> rule = parser.parseRule(NSS);
final Collection<Object> result = rule.getValues(backend, uri);
@@ -79,7 +79,7 @@ public class HtmlFunctionsTest extends AbstractTestBase {
assertThat("String end", s, CoreMatchers.endsWith("</p>"));
}
- final RdfPathParser<Value> parser2 = createParserFromString("fn:css(\"p#p2\", foo:html) :: xsd:string");
+ final LdPathParser<Value> parser2 = createParserFromString("fn:css(\"p#p2\", foo:html) :: xsd:string");
final FieldMapping<Object, Value> rule2 = parser2.parseRule(NSS);
final Collection<Object> result2 = rule2.getValues(backend, uri);
http://git-wip-us.apache.org/repos/asf/incubator-marmotta/blob/6591259a/libraries/ldpath/ldpath-functions-math/src/test/java/org/apache/marmotta/ldpath/model/functions/math/MathFunctionTest.java
----------------------------------------------------------------------
diff --git a/libraries/ldpath/ldpath-functions-math/src/test/java/org/apache/marmotta/ldpath/model/functions/math/MathFunctionTest.java b/libraries/ldpath/ldpath-functions-math/src/test/java/org/apache/marmotta/ldpath/model/functions/math/MathFunctionTest.java
index 1696341..0018de9 100644
--- a/libraries/ldpath/ldpath-functions-math/src/test/java/org/apache/marmotta/ldpath/model/functions/math/MathFunctionTest.java
+++ b/libraries/ldpath/ldpath-functions-math/src/test/java/org/apache/marmotta/ldpath/model/functions/math/MathFunctionTest.java
@@ -22,7 +22,7 @@ import java.util.Random;
import org.apache.marmotta.ldpath.model.fields.FieldMapping;
import org.apache.marmotta.ldpath.parser.ParseException;
-import org.apache.marmotta.ldpath.parser.RdfPathParser;
+import org.apache.marmotta.ldpath.parser.LdPathParser;
import org.apache.marmotta.ldpath.test.AbstractTestBase;
import org.hamcrest.CoreMatchers;
import org.junit.Assert;
@@ -100,7 +100,7 @@ public class MathFunctionTest extends AbstractTestBase {
dMin = Math.min(dMin, dData[i]);
}
- final RdfPathParser<Value> intParser = createParserFromString("fn:min(<" + iProp.stringValue() + ">) :: xsd:int");
+ final LdPathParser<Value> intParser = createParserFromString("fn:min(<" + iProp.stringValue() + ">) :: xsd:int");
final FieldMapping<Object, Value> intRule = intParser.parseRule(NSS);
final Collection<Object> intResult = intRule.getValues(backend, subject);
@@ -109,7 +109,7 @@ public class MathFunctionTest extends AbstractTestBase {
Assert.assertTrue("Integer (type)", intNext instanceof Integer);
Assert.assertEquals("Integer (result)", iMin, intNext);
- final RdfPathParser<Value> longParser = createParserFromString("fn:min(<" + lProp.stringValue() + ">) :: xsd:long");
+ final LdPathParser<Value> longParser = createParserFromString("fn:min(<" + lProp.stringValue() + ">) :: xsd:long");
final FieldMapping<Object, Value> longRule = longParser.parseRule(NSS);
final Collection<Object> longResult = longRule.getValues(backend, subject);
@@ -118,7 +118,7 @@ public class MathFunctionTest extends AbstractTestBase {
Assert.assertTrue("Long (type)", longNext instanceof Long);
Assert.assertEquals("Long (result)", lMin, longNext);
- final RdfPathParser<Value> floatParser = createParserFromString("fn:min(<" + fProp.stringValue() + ">) :: xsd:float");
+ final LdPathParser<Value> floatParser = createParserFromString("fn:min(<" + fProp.stringValue() + ">) :: xsd:float");
final FieldMapping<Object, Value> floatRule = floatParser.parseRule(NSS);
final Collection<Object> floatResult = floatRule.getValues(backend, subject);
@@ -127,7 +127,7 @@ public class MathFunctionTest extends AbstractTestBase {
Assert.assertTrue("Float (type)", floatNext instanceof Float);
Assert.assertEquals("Float (result)", fMin, floatNext);
- final RdfPathParser<Value> doubleParser = createParserFromString("fn:min(<" + dProp.stringValue() + ">) :: xsd:double");
+ final LdPathParser<Value> doubleParser = createParserFromString("fn:min(<" + dProp.stringValue() + ">) :: xsd:double");
final FieldMapping<Object, Value> doubleRule = doubleParser.parseRule(NSS);
final Collection<Object> doubleResult = doubleRule.getValues(backend, subject);
@@ -150,7 +150,7 @@ public class MathFunctionTest extends AbstractTestBase {
dMax = Math.max(dMax, dData[i]);
}
- final RdfPathParser<Value> intParser = createParserFromString("fn:max(<" + iProp.stringValue() + ">) :: xsd:int");
+ final LdPathParser<Value> intParser = createParserFromString("fn:max(<" + iProp.stringValue() + ">) :: xsd:int");
final FieldMapping<Object, Value> intRule = intParser.parseRule(NSS);
final Collection<Object> intResult = intRule.getValues(backend, subject);
@@ -159,7 +159,7 @@ public class MathFunctionTest extends AbstractTestBase {
Assert.assertTrue("Integer (type)", intNext instanceof Integer);
Assert.assertEquals("Integer (result)", iMax, intNext);
- final RdfPathParser<Value> longParser = createParserFromString("fn:max(<" + lProp.stringValue() + ">) :: xsd:long");
+ final LdPathParser<Value> longParser = createParserFromString("fn:max(<" + lProp.stringValue() + ">) :: xsd:long");
final FieldMapping<Object, Value> longRule = longParser.parseRule(NSS);
final Collection<Object> longResult = longRule.getValues(backend, subject);
@@ -168,7 +168,7 @@ public class MathFunctionTest extends AbstractTestBase {
Assert.assertTrue("Long (type)", longNext instanceof Long);
Assert.assertEquals("Long (result)", lMax, longNext);
- final RdfPathParser<Value> floatParser = createParserFromString("fn:max(<" + fProp.stringValue() + ">) :: xsd:float");
+ final LdPathParser<Value> floatParser = createParserFromString("fn:max(<" + fProp.stringValue() + ">) :: xsd:float");
final FieldMapping<Object, Value> floatRule = floatParser.parseRule(NSS);
final Collection<Object> floatResult = floatRule.getValues(backend, subject);
@@ -177,7 +177,7 @@ public class MathFunctionTest extends AbstractTestBase {
Assert.assertTrue("Float (type)", floatNext instanceof Float);
Assert.assertEquals("Float (result)", fMax, floatNext);
- final RdfPathParser<Value> doubleParser = createParserFromString("fn:max(<" + dProp.stringValue() + ">) :: xsd:double");
+ final LdPathParser<Value> doubleParser = createParserFromString("fn:max(<" + dProp.stringValue() + ">) :: xsd:double");
final FieldMapping<Object, Value> doubleRule = doubleParser.parseRule(NSS);
final Collection<Object> doubleResult = doubleRule.getValues(backend, subject);
@@ -196,7 +196,7 @@ public class MathFunctionTest extends AbstractTestBase {
dMin = Math.min(dMin, dData[i]);
}
- final RdfPathParser<Value> floatParser = createParserFromString("fn:round(<" + fProp.stringValue() + ">) :: xsd:int");
+ final LdPathParser<Value> floatParser = createParserFromString("fn:round(<" + fProp.stringValue() + ">) :: xsd:int");
final FieldMapping<Object, Value> floatRule = floatParser.parseRule(NSS);
final Collection<Object> floatResult = floatRule.getValues(backend, subject);
@@ -205,7 +205,7 @@ public class MathFunctionTest extends AbstractTestBase {
Assert.assertThat("round[Float] (result)", floatResult, CoreMatchers.hasItem(Math.round(element)));
}
- final RdfPathParser<Value> doubleParser = createParserFromString("fn:round(<" + dProp.stringValue() + ">) :: xsd:long");
+ final LdPathParser<Value> doubleParser = createParserFromString("fn:round(<" + dProp.stringValue() + ">) :: xsd:long");
final FieldMapping<Object, Value> doubleRule = doubleParser.parseRule(NSS);
final Collection<Object> doubleResult = doubleRule.getValues(backend, subject);
@@ -230,7 +230,7 @@ public class MathFunctionTest extends AbstractTestBase {
dSum += dData[i];
}
- final RdfPathParser<Value> intParser = createParserFromString("fn:sum(<" + iProp.stringValue() + ">) :: xsd:int");
+ final LdPathParser<Value> intParser = createParserFromString("fn:sum(<" + iProp.stringValue() + ">) :: xsd:int");
final FieldMapping<Object, Value> intRule = intParser.parseRule(NSS);
final Collection<Object> intResult = intRule.getValues(backend, subject);
@@ -239,7 +239,7 @@ public class MathFunctionTest extends AbstractTestBase {
Assert.assertTrue("Integer (type)", intNext instanceof Integer);
Assert.assertEquals("Integer (result)", iSum, intNext);
- final RdfPathParser<Value> longParser = createParserFromString("fn:sum(<" + lProp.stringValue() + ">) :: xsd:long");
+ final LdPathParser<Value> longParser = createParserFromString("fn:sum(<" + lProp.stringValue() + ">) :: xsd:long");
final FieldMapping<Object, Value> longRule = longParser.parseRule(NSS);
final Collection<Object> longResult = longRule.getValues(backend, subject);
@@ -248,7 +248,7 @@ public class MathFunctionTest extends AbstractTestBase {
Assert.assertTrue("Long (type)", longNext instanceof Long);
Assert.assertEquals("Long (result)", lSum, longNext);
- final RdfPathParser<Value> floatParser = createParserFromString("fn:sum(<" + fProp.stringValue() + ">) :: xsd:float");
+ final LdPathParser<Value> floatParser = createParserFromString("fn:sum(<" + fProp.stringValue() + ">) :: xsd:float");
final FieldMapping<Object, Value> floatRule = floatParser.parseRule(NSS);
final Collection<Object> floatResult = floatRule.getValues(backend, subject);
@@ -257,7 +257,7 @@ public class MathFunctionTest extends AbstractTestBase {
Assert.assertTrue("Float (type)", floatNext instanceof Float);
Assert.assertEquals("Float (result)", fSum, floatNext);
- final RdfPathParser<Value> doubleParser = createParserFromString("fn:sum(<" + dProp.stringValue() + ">) :: xsd:double");
+ final LdPathParser<Value> doubleParser = createParserFromString("fn:sum(<" + dProp.stringValue() + ">) :: xsd:double");
final FieldMapping<Object, Value> doubleRule = doubleParser.parseRule(NSS);
final Collection<Object> doubleResult = doubleRule.getValues(backend, subject);
http://git-wip-us.apache.org/repos/asf/incubator-marmotta/blob/6591259a/libraries/ldpath/ldpath-functions-text/src/test/java/org/apache/marmotta/ldpath/model/tests/functions/text/StringTestTest.java
----------------------------------------------------------------------
diff --git a/libraries/ldpath/ldpath-functions-text/src/test/java/org/apache/marmotta/ldpath/model/tests/functions/text/StringTestTest.java b/libraries/ldpath/ldpath-functions-text/src/test/java/org/apache/marmotta/ldpath/model/tests/functions/text/StringTestTest.java
index 713508f..2da31a7 100644
--- a/libraries/ldpath/ldpath-functions-text/src/test/java/org/apache/marmotta/ldpath/model/tests/functions/text/StringTestTest.java
+++ b/libraries/ldpath/ldpath-functions-text/src/test/java/org/apache/marmotta/ldpath/model/tests/functions/text/StringTestTest.java
@@ -24,7 +24,7 @@ import java.util.UUID;
import org.apache.marmotta.ldpath.api.tests.NodeTest;
import org.apache.marmotta.ldpath.parser.ParseException;
-import org.apache.marmotta.ldpath.parser.RdfPathParser;
+import org.apache.marmotta.ldpath.parser.LdPathParser;
import org.apache.marmotta.ldpath.test.AbstractTestBase;
import org.junit.After;
import org.junit.AfterClass;
@@ -101,7 +101,7 @@ public class StringTestTest extends AbstractTestBase {
}
private boolean checkTest(String ldPathTest, URI context) throws ParseException {
- final RdfPathParser<Value> parser = createParserFromString(ldPathTest);
+ final LdPathParser<Value> parser = createParserFromString(ldPathTest);
final NodeTest<Value> test = parser.parseTest(NSS);
return test.accept(backend, context, context);
}
http://git-wip-us.apache.org/repos/asf/incubator-marmotta/blob/6591259a/libraries/ldpath/ldpath-functions-xml/src/test/java/org/apache/marmotta/ldpath/model/functions/xml/RemoveXmlTagsFunctionTest.java
----------------------------------------------------------------------
diff --git a/libraries/ldpath/ldpath-functions-xml/src/test/java/org/apache/marmotta/ldpath/model/functions/xml/RemoveXmlTagsFunctionTest.java b/libraries/ldpath/ldpath-functions-xml/src/test/java/org/apache/marmotta/ldpath/model/functions/xml/RemoveXmlTagsFunctionTest.java
index b4b2e7c..070d22b 100644
--- a/libraries/ldpath/ldpath-functions-xml/src/test/java/org/apache/marmotta/ldpath/model/functions/xml/RemoveXmlTagsFunctionTest.java
+++ b/libraries/ldpath/ldpath-functions-xml/src/test/java/org/apache/marmotta/ldpath/model/functions/xml/RemoveXmlTagsFunctionTest.java
@@ -22,7 +22,7 @@ import java.util.Collection;
import org.apache.marmotta.ldpath.model.fields.FieldMapping;
import org.apache.marmotta.ldpath.parser.ParseException;
-import org.apache.marmotta.ldpath.parser.RdfPathParser;
+import org.apache.marmotta.ldpath.parser.LdPathParser;
import org.apache.marmotta.ldpath.test.AbstractTestBase;
import org.junit.Assert;
import org.junit.Before;
@@ -47,7 +47,7 @@ public class RemoveXmlTagsFunctionTest extends AbstractTestBase {
final URI context = repository.getValueFactory().createURI(NSS.get("ex") + "Text");
- final RdfPathParser<Value> parser = createParserFromString("fn:removeTags(foo:formatted) :: xsd:string");
+ final LdPathParser<Value> parser = createParserFromString("fn:removeTags(foo:formatted) :: xsd:string");
final FieldMapping<Object, Value> rule = parser.parseRule(NSS);
final Collection<Object> values = rule.getValues(backend, context);
http://git-wip-us.apache.org/repos/asf/incubator-marmotta/blob/6591259a/libraries/ldpath/ldpath-functions-xml/src/test/java/org/apache/marmotta/ldpath/model/functions/xml/XPathFunctionTest.java
----------------------------------------------------------------------
diff --git a/libraries/ldpath/ldpath-functions-xml/src/test/java/org/apache/marmotta/ldpath/model/functions/xml/XPathFunctionTest.java b/libraries/ldpath/ldpath-functions-xml/src/test/java/org/apache/marmotta/ldpath/model/functions/xml/XPathFunctionTest.java
index 613d1ad..87eaa6c 100644
--- a/libraries/ldpath/ldpath-functions-xml/src/test/java/org/apache/marmotta/ldpath/model/functions/xml/XPathFunctionTest.java
+++ b/libraries/ldpath/ldpath-functions-xml/src/test/java/org/apache/marmotta/ldpath/model/functions/xml/XPathFunctionTest.java
@@ -24,7 +24,7 @@ import java.util.List;
import org.apache.marmotta.ldpath.model.fields.FieldMapping;
import org.apache.marmotta.ldpath.parser.ParseException;
-import org.apache.marmotta.ldpath.parser.RdfPathParser;
+import org.apache.marmotta.ldpath.parser.LdPathParser;
import org.apache.marmotta.ldpath.test.AbstractTestBase;
import org.junit.Assert;
import org.junit.Before;
@@ -73,7 +73,7 @@ public class XPathFunctionTest extends AbstractTestBase {
public void testXpathFunction() throws ParseException {
final URI ctx = repository.getValueFactory().createURI(NSS.get("ex") + "Quiz");
- final RdfPathParser<Value> parser = createParserFromString("fn:xpath(\"/quiz/question[" +
+ final LdPathParser<Value> parser = createParserFromString("fn:xpath(\"/quiz/question[" +
index +
"]/answers/answer[@correct='true']/text()\", foo:xml) :: xsd:string");
final FieldMapping<Object, Value> rule = parser.parseRule(NSS);