summaryrefslogtreecommitdiff
path: root/src/main/java/com/amazon/carbonado/cursor
diff options
context:
space:
mode:
Diffstat (limited to 'src/main/java/com/amazon/carbonado/cursor')
-rw-r--r--src/main/java/com/amazon/carbonado/cursor/FilteredCursor.java1
-rw-r--r--src/main/java/com/amazon/carbonado/cursor/FilteredCursorGenerator.java6
-rw-r--r--src/main/java/com/amazon/carbonado/cursor/GroupedCursor.java1
-rw-r--r--src/main/java/com/amazon/carbonado/cursor/MergeSortBuffer.java8
-rw-r--r--src/main/java/com/amazon/carbonado/cursor/MultiTransformedCursor.java1
-rw-r--r--src/main/java/com/amazon/carbonado/cursor/SortedCursor.java1
-rw-r--r--src/main/java/com/amazon/carbonado/cursor/ThrottledCursor.java1
-rw-r--r--src/main/java/com/amazon/carbonado/cursor/TransformedCursor.java1
-rw-r--r--src/main/java/com/amazon/carbonado/cursor/WorkFilePool.java1
9 files changed, 20 insertions, 1 deletions
diff --git a/src/main/java/com/amazon/carbonado/cursor/FilteredCursor.java b/src/main/java/com/amazon/carbonado/cursor/FilteredCursor.java
index 59cb941..93b7bc0 100644
--- a/src/main/java/com/amazon/carbonado/cursor/FilteredCursor.java
+++ b/src/main/java/com/amazon/carbonado/cursor/FilteredCursor.java
@@ -153,6 +153,7 @@ public abstract class FilteredCursor<S> extends AbstractCursor<S> {
throw new NoSuchElementException();
}
+ @Override
public int skipNext(int amount) throws FetchException {
if (amount <= 0) {
if (amount < 0) {
diff --git a/src/main/java/com/amazon/carbonado/cursor/FilteredCursorGenerator.java b/src/main/java/com/amazon/carbonado/cursor/FilteredCursorGenerator.java
index 4e58361..c7dec07 100644
--- a/src/main/java/com/amazon/carbonado/cursor/FilteredCursorGenerator.java
+++ b/src/main/java/com/amazon/carbonado/cursor/FilteredCursorGenerator.java
@@ -18,7 +18,6 @@
package com.amazon.carbonado.cursor;
-import java.lang.reflect.InvocationTargetException;
import java.lang.reflect.Method;
import java.util.ArrayList;
@@ -217,6 +216,7 @@ class FilteredCursorGenerator {
Validator() {
}
+ @Override
public Object visit(PropertyFilter<S> filter, Object param) {
ChainedProperty<S> chained = filter.getChainedProperty();
@@ -304,6 +304,7 @@ class FilteredCursorGenerator {
return mSubFilters;
}
+ @Override
public Object visit(OrFilter<S> filter, Object param) {
Label failLocation = mIsAllowedBuilder.createLabel();
// Inherit success location to short-circuit if 'or' test succeeds.
@@ -315,6 +316,7 @@ class FilteredCursorGenerator {
return null;
}
+ @Override
public Object visit(AndFilter<S> filter, Object param) {
Label successLocation = mIsAllowedBuilder.createLabel();
// Inherit fail location to short-circuit if 'and' test fails.
@@ -326,6 +328,7 @@ class FilteredCursorGenerator {
return null;
}
+ @Override
public Object visit(PropertyFilter<S> filter, Object param) {
TypeDesc type = TypeDesc.forClass(filter.getChainedProperty().getType());
String fieldName = addFilterField(filter, type);
@@ -334,6 +337,7 @@ class FilteredCursorGenerator {
return null;
}
+ @Override
public Object visit(ExistsFilter<S> filter, Object param) {
// Load join property value to stack.
CodeBuilder b = mIsAllowedBuilder;
diff --git a/src/main/java/com/amazon/carbonado/cursor/GroupedCursor.java b/src/main/java/com/amazon/carbonado/cursor/GroupedCursor.java
index 6d9afc5..135d817 100644
--- a/src/main/java/com/amazon/carbonado/cursor/GroupedCursor.java
+++ b/src/main/java/com/amazon/carbonado/cursor/GroupedCursor.java
@@ -194,6 +194,7 @@ public abstract class GroupedCursor<S, G> extends AbstractCursor<G> {
throw new NoSuchElementException();
}
+ @Override
public int skipNext(int amount) throws FetchException {
if (amount <= 0) {
if (amount < 0) {
diff --git a/src/main/java/com/amazon/carbonado/cursor/MergeSortBuffer.java b/src/main/java/com/amazon/carbonado/cursor/MergeSortBuffer.java
index b02f9bf..31359e8 100644
--- a/src/main/java/com/amazon/carbonado/cursor/MergeSortBuffer.java
+++ b/src/main/java/com/amazon/carbonado/cursor/MergeSortBuffer.java
@@ -189,6 +189,7 @@ public class MergeSortBuffer<S extends Storable> extends AbstractCollection<S>
mComparator = comparator;
}
+ @Override
public boolean add(S storable) {
if (mPreparer == null) {
mPreparer = new FromStorable(storable);
@@ -307,10 +308,12 @@ public class MergeSortBuffer<S extends Storable> extends AbstractCollection<S>
return true;
}
+ @Override
public int size() {
return mTotalSize;
}
+ @Override
public Iterator<S> iterator() {
return iterator(mFilesInUse);
}
@@ -342,6 +345,7 @@ public class MergeSortBuffer<S extends Storable> extends AbstractCollection<S>
return new Merger<S>(pq);
}
+ @Override
public void clear() {
if (mPreparer instanceof FromStorable) {
mPreparer = null;
@@ -474,6 +478,7 @@ public class MergeSortBuffer<S extends Storable> extends AbstractCollection<S>
mSize = size;
}
+ @Override
S peek() {
int pos = mPos;
if (pos >= mSize) {
@@ -482,6 +487,7 @@ public class MergeSortBuffer<S extends Storable> extends AbstractCollection<S>
return mArray[pos];
}
+ @Override
S next() {
int pos = mPos;
if (pos >= mSize) {
@@ -508,6 +514,7 @@ public class MergeSortBuffer<S extends Storable> extends AbstractCollection<S>
mIn = in;
}
+ @Override
S peek() {
if (mNext != null) {
return mNext;
@@ -528,6 +535,7 @@ public class MergeSortBuffer<S extends Storable> extends AbstractCollection<S>
return mNext;
}
+ @Override
S next() {
S next = peek();
mNext = null;
diff --git a/src/main/java/com/amazon/carbonado/cursor/MultiTransformedCursor.java b/src/main/java/com/amazon/carbonado/cursor/MultiTransformedCursor.java
index 4b4a25a..fafb55f 100644
--- a/src/main/java/com/amazon/carbonado/cursor/MultiTransformedCursor.java
+++ b/src/main/java/com/amazon/carbonado/cursor/MultiTransformedCursor.java
@@ -114,6 +114,7 @@ public abstract class MultiTransformedCursor<S, T> extends AbstractCursor<T> {
throw new NoSuchElementException();
}
+ @Override
public int skipNext(int amount) throws FetchException {
if (amount <= 0) {
if (amount < 0) {
diff --git a/src/main/java/com/amazon/carbonado/cursor/SortedCursor.java b/src/main/java/com/amazon/carbonado/cursor/SortedCursor.java
index 2a05493..e4e7b68 100644
--- a/src/main/java/com/amazon/carbonado/cursor/SortedCursor.java
+++ b/src/main/java/com/amazon/carbonado/cursor/SortedCursor.java
@@ -341,6 +341,7 @@ public class SortedCursor<S> extends AbstractCursor<S> {
}
}
+ @Override
public int skipNext(int amount) throws FetchException {
if (amount <= 0) {
if (amount < 0) {
diff --git a/src/main/java/com/amazon/carbonado/cursor/ThrottledCursor.java b/src/main/java/com/amazon/carbonado/cursor/ThrottledCursor.java
index d108d95..a349782 100644
--- a/src/main/java/com/amazon/carbonado/cursor/ThrottledCursor.java
+++ b/src/main/java/com/amazon/carbonado/cursor/ThrottledCursor.java
@@ -87,6 +87,7 @@ public class ThrottledCursor<S> extends AbstractCursor<S> {
}
}
+ @Override
public int skipNext(int amount) throws FetchException {
if (amount <= 0) {
if (amount < 0) {
diff --git a/src/main/java/com/amazon/carbonado/cursor/TransformedCursor.java b/src/main/java/com/amazon/carbonado/cursor/TransformedCursor.java
index 46dedd1..199cc84 100644
--- a/src/main/java/com/amazon/carbonado/cursor/TransformedCursor.java
+++ b/src/main/java/com/amazon/carbonado/cursor/TransformedCursor.java
@@ -103,6 +103,7 @@ public abstract class TransformedCursor<S, T> extends AbstractCursor<T> {
throw new NoSuchElementException();
}
+ @Override
public int skipNext(int amount) throws FetchException {
if (amount <= 0) {
if (amount < 0) {
diff --git a/src/main/java/com/amazon/carbonado/cursor/WorkFilePool.java b/src/main/java/com/amazon/carbonado/cursor/WorkFilePool.java
index 442d45c..32bf4e0 100644
--- a/src/main/java/com/amazon/carbonado/cursor/WorkFilePool.java
+++ b/src/main/java/com/amazon/carbonado/cursor/WorkFilePool.java
@@ -155,6 +155,7 @@ class WorkFilePool {
String threadName = "MergeSortBuffer shutdown (" + tempDir + ')';
mShutdownHook = new Thread(threadName) {
+ @Override
public void run() {
// Notify users of work files and wait for them to close.
synchronized (mWorkFileUsers) {