|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.elasticsearch.cluster.routing.PlainShardsIterator
public class PlainShardsIterator
Field Summary | |
---|---|
protected java.util.List<ShardRouting> |
shards
|
Constructor Summary | |
---|---|
PlainShardsIterator(java.util.List<ShardRouting> shards)
|
|
PlainShardsIterator(java.util.List<ShardRouting> shards,
int index)
|
Method Summary | |
---|---|
boolean |
hasNext()
|
boolean |
hasNextActive()
Is there an active shard we can iterate to. |
boolean |
hasNextAssigned()
Is there an assigned shard we can iterate to. |
java.util.Iterator<ShardRouting> |
iterator()
|
ShardRouting |
next()
|
ShardRouting |
nextActive()
Returns the next active shard, or throws NoSuchElementException . |
ShardRouting |
nextActiveOrNull()
Returns the next active shard, or null. |
ShardRouting |
nextAssigned()
Returns the next assigned shard, or throws NoSuchElementException . |
ShardRouting |
nextAssignedOrNull()
Returns the next assigned shard, or null. |
void |
remove()
|
ShardsIterator |
reset()
Resets the iterator. |
int |
size()
The number of shard routing instances. |
int |
sizeActive()
The number of active shard routing instances. |
int |
sizeAssigned()
The number of assigned shard routing instances. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Methods inherited from interface org.elasticsearch.cluster.routing.ShardsIterator |
---|
equals, hashCode |
Field Detail |
---|
protected final java.util.List<ShardRouting> shards
Constructor Detail |
---|
public PlainShardsIterator(java.util.List<ShardRouting> shards)
public PlainShardsIterator(java.util.List<ShardRouting> shards, int index)
Method Detail |
---|
public java.util.Iterator<ShardRouting> iterator()
iterator
in interface java.lang.Iterable<ShardRouting>
public ShardsIterator reset()
ShardsIterator
reset
in interface ShardsIterator
public boolean hasNext()
hasNext
in interface java.util.Iterator<ShardRouting>
public ShardRouting next() throws java.util.NoSuchElementException
next
in interface java.util.Iterator<ShardRouting>
java.util.NoSuchElementException
public void remove()
remove
in interface java.util.Iterator<ShardRouting>
public int size()
ShardsIterator
size
in interface ShardsIterator
public int sizeActive()
ShardsIterator
sizeActive
in interface ShardsIterator
ShardRouting.active()
public boolean hasNextActive()
ShardsIterator
hasNextActive
in interface ShardsIterator
ShardRouting.active()
public ShardRouting nextActive() throws java.util.NoSuchElementException
ShardsIterator
NoSuchElementException
.
nextActive
in interface ShardsIterator
java.util.NoSuchElementException
ShardRouting.active()
public ShardRouting nextActiveOrNull() throws java.util.NoSuchElementException
ShardsIterator
nextActiveOrNull
in interface ShardsIterator
java.util.NoSuchElementException
ShardRouting.active()
public int sizeAssigned()
ShardsIterator
sizeAssigned
in interface ShardsIterator
ShardRouting.assignedToNode()
public boolean hasNextAssigned()
ShardsIterator
hasNextAssigned
in interface ShardsIterator
ShardRouting.assignedToNode()
public ShardRouting nextAssigned() throws java.util.NoSuchElementException
ShardsIterator
NoSuchElementException
.
nextAssigned
in interface ShardsIterator
java.util.NoSuchElementException
ShardRouting.assignedToNode()
public ShardRouting nextAssignedOrNull()
ShardsIterator
nextAssignedOrNull
in interface ShardsIterator
ShardRouting.assignedToNode()
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |