cleamup ShardIter#reset method
don't have teh reset method return an instance, as it might confuse usage into thinking it might be a different instance
This commit is contained in:
parent
074b89b7ad
commit
13845e47d6
|
@ -56,12 +56,6 @@ public class PlainShardIterator extends PlainShardsIterator implements ShardIter
|
|||
this.shardId = shardId;
|
||||
}
|
||||
|
||||
@Override
|
||||
public ShardIterator reset() {
|
||||
super.reset();
|
||||
return this;
|
||||
}
|
||||
|
||||
@Override
|
||||
public ShardId shardId() {
|
||||
return this.shardId;
|
||||
|
|
|
@ -54,9 +54,8 @@ public class PlainShardsIterator implements ShardsIterator {
|
|||
}
|
||||
|
||||
@Override
|
||||
public ShardsIterator reset() {
|
||||
public void reset() {
|
||||
this.counter = this.index;
|
||||
return this;
|
||||
}
|
||||
|
||||
@Override
|
||||
|
|
|
@ -34,5 +34,5 @@ public interface ShardIterator extends ShardsIterator {
|
|||
/**
|
||||
* Resets the iterator.
|
||||
*/
|
||||
ShardIterator reset();
|
||||
void reset();
|
||||
}
|
||||
|
|
|
@ -27,16 +27,18 @@ public interface ShardsIterator {
|
|||
/**
|
||||
* Resets the iterator to its initial state.
|
||||
*/
|
||||
ShardsIterator reset();
|
||||
void reset();
|
||||
|
||||
/**
|
||||
* The number of shard routing instances.
|
||||
*
|
||||
* @return number of shard routing instances in this iterator
|
||||
*/
|
||||
int size();
|
||||
|
||||
/**
|
||||
* The number of active shard routing instances
|
||||
*
|
||||
* @return number of active shard routing instances
|
||||
*/
|
||||
int sizeActive();
|
||||
|
@ -63,6 +65,7 @@ public interface ShardsIterator {
|
|||
|
||||
/**
|
||||
* Return the number of shards remaining in this {@link ShardsIterator}
|
||||
*
|
||||
* @return number of shard remaining
|
||||
*/
|
||||
int remaining();
|
||||
|
|
Loading…
Reference in New Issue