public class OrderByMoveIndexBlockingQueue<Solution_> extends Object
Modifier and Type | Class and Description |
---|---|
static class |
OrderByMoveIndexBlockingQueue.MoveResult<Solution_> |
Constructor and Description |
---|
OrderByMoveIndexBlockingQueue(int capacity) |
Modifier and Type | Method and Description |
---|---|
void |
addExceptionThrown(int moveThreadIndex,
Throwable throwable)
This method is thread-safe.
|
void |
addMove(int moveThreadIndex,
int stepIndex,
int moveIndex,
Move<Solution_> move,
Score score)
This method is thread-safe.
|
void |
addUndoableMove(int moveThreadIndex,
int stepIndex,
int moveIndex,
Move<Solution_> move)
This method is thread-safe.
|
void |
startNextStep(int stepIndex)
Not thread-safe.
|
OrderByMoveIndexBlockingQueue.MoveResult<Solution_> |
take()
Not thread-safe.
|
public void startNextStep(int stepIndex)
stepIndex
- at least 0public void addUndoableMove(int moveThreadIndex, int stepIndex, int moveIndex, Move<Solution_> move)
moveThreadIndex
- 0 <= moveThreadIndex < moveThreadCount
stepIndex
- at least 0moveIndex
- at least 0move
- never nullBlockingQueue.add(Object)
public void addMove(int moveThreadIndex, int stepIndex, int moveIndex, Move<Solution_> move, Score score)
moveThreadIndex
- 0 <= moveThreadIndex < moveThreadCount
stepIndex
- at least 0moveIndex
- at least 0move
- never nullscore
- never nullBlockingQueue.add(Object)
public void addExceptionThrown(int moveThreadIndex, Throwable throwable)
moveThreadIndex
- 0 <= moveThreadIndex < moveThreadCount
throwable
- never nullpublic OrderByMoveIndexBlockingQueue.MoveResult<Solution_> take() throws InterruptedException
InterruptedException
- if interruptedBlockingQueue.take()
Copyright © 2006–2018 JBoss by Red Hat. All rights reserved.