diff options
Diffstat (limited to 'src/uk/ac/ox/cs/pagoda/query/GapTupleIterator.java')
| -rw-r--r-- | src/uk/ac/ox/cs/pagoda/query/GapTupleIterator.java | 30 |
1 files changed, 30 insertions, 0 deletions
diff --git a/src/uk/ac/ox/cs/pagoda/query/GapTupleIterator.java b/src/uk/ac/ox/cs/pagoda/query/GapTupleIterator.java new file mode 100644 index 0000000..58303bb --- /dev/null +++ b/src/uk/ac/ox/cs/pagoda/query/GapTupleIterator.java | |||
| @@ -0,0 +1,30 @@ | |||
| 1 | package uk.ac.ox.cs.pagoda.query; | ||
| 2 | |||
| 3 | import java.util.Iterator; | ||
| 4 | |||
| 5 | import uk.ac.ox.cs.JRDFox.JRDFStoreException; | ||
| 6 | import uk.ac.ox.cs.JRDFox.store.DataStore; | ||
| 7 | |||
| 8 | public abstract class GapTupleIterator<T> implements Iterator<T> { | ||
| 9 | |||
| 10 | public static final String gapPredicateSuffix = "_AUXg"; | ||
| 11 | |||
| 12 | public static final String getGapPredicate(String predicateIRI) { | ||
| 13 | if (predicateIRI.startsWith("<")) | ||
| 14 | return predicateIRI.replace(">", gapPredicateSuffix + ">"); | ||
| 15 | return predicateIRI + gapPredicateSuffix; | ||
| 16 | } | ||
| 17 | |||
| 18 | public void compile(String programText) throws JRDFStoreException {} | ||
| 19 | |||
| 20 | public abstract boolean isValid(); | ||
| 21 | |||
| 22 | public abstract void save(String file); | ||
| 23 | |||
| 24 | public abstract void addBackTo() throws JRDFStoreException; | ||
| 25 | |||
| 26 | public abstract void addTo(DataStore store) throws JRDFStoreException; | ||
| 27 | |||
| 28 | public abstract void clear(); | ||
| 29 | |||
| 30 | } | ||
