de.grogra.xl.impl.base
Class GraphQueue
java.lang.Object
java.io.OutputStream
de.grogra.util.OutputQueue
de.grogra.util.HierarchicalQueue
de.grogra.xl.impl.base.GraphQueue
- All Implemented Interfaces:
- Queue, java.io.Closeable, java.io.DataOutput, java.io.Flushable, java.io.ObjectOutput, java.util.concurrent.Executor
- Direct Known Subclasses:
- GraphQueueImpl
public abstract class GraphQueue
- extends HierarchicalQueue
- implements Queue, java.util.concurrent.Executor
Method Summary |
abstract void |
addEdgeBits(java.lang.Object source,
java.lang.Object target,
int edges)
|
abstract void |
addNode(java.lang.Object node)
|
abstract void |
addUndirectedEdgeBits(java.lang.Object source,
java.lang.Object target,
int edges)
|
void |
clear()
Clears the queue. |
protected void |
clearSegmentsToExcludeImpl(int[] segs)
|
abstract
|
connect(N source,
N target,
P param,
Connector<N,P> redirector)
|
abstract void |
connectAdjacent(java.lang.Object start,
java.lang.Object end,
int edges)
|
abstract
|
connectIncoming(N source,
N target,
Operator<N> operator)
|
abstract
|
connectOutgoing(N source,
N target,
Operator<N> operator)
|
abstract void |
copyIncoming(java.lang.Object source,
java.lang.Object target,
int edges)
|
abstract void |
copyIncoming(java.lang.Object source,
java.lang.Object target,
int edges,
int copyMask,
int addMask)
|
abstract void |
copyOutgoing(java.lang.Object source,
java.lang.Object target,
int edges)
|
abstract void |
copyOutgoing(java.lang.Object source,
java.lang.Object target,
int edges,
int copyMask,
int addMask)
|
protected abstract GraphQueue.Processor |
createProcessor()
|
abstract void |
deleteCurrentEdges(java.lang.Object node,
int edges,
boolean outgoing)
|
abstract void |
deleteEdgeBits(java.lang.Object source,
java.lang.Object target,
int edges)
|
abstract void |
deleteNode(java.lang.Object node)
|
abstract void |
embedInterpretive(java.lang.Object interpreted,
java.lang.Object start,
java.lang.Object end)
|
QueueDescriptor<?> |
getDescriptor()
Returns the descriptor which was used to create this queue. |
protected abstract RuntimeModel |
getModel()
|
void |
markSegment(int n)
|
abstract void |
moveIncoming(java.lang.Object source,
java.lang.Object target,
int edges)
|
abstract void |
moveOutgoing(java.lang.Object source,
java.lang.Object target,
int edges)
|
boolean |
process(int[] segments)
Processes all queued tasks. |
void |
resetToSegment(int n)
|
Methods inherited from class de.grogra.util.HierarchicalQueue |
beginLevel, beginSkipBlock, cloneData, createData, discardLevel, endLevel, endSkipBlock, getCursor, getData, hasItems, hasItemsInCurrentLevel, moveTo, restore, setItemSize, writeItem, writeObject, writeObjectInStream |
Methods inherited from class de.grogra.util.OutputQueue |
close, dump, flush, write, write, write, writeBoolean, writeByte, writeBytes, writeChar, writeChars, writeDouble, writeFloat, writeInt, writeLong, writeObjectInQueue, writeShort, writeUTF |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Methods inherited from interface java.util.concurrent.Executor |
execute |
Methods inherited from interface java.io.ObjectOutput |
close, flush, write, write, write |
Methods inherited from interface java.io.DataOutput |
writeBoolean, writeByte, writeBytes, writeChar, writeChars, writeDouble, writeFloat, writeInt, writeLong, writeShort, writeUTF |
ADD_EDGE_DESCRIPTOR
public static final GraphQueue.AddEdgeDescriptor ADD_EDGE_DESCRIPTOR
ADD_NODE_DESCRIPTOR
public static final GraphQueue.AddNodeDescriptor ADD_NODE_DESCRIPTOR
ADD_UNDIRECTED_EDGE_DESCRIPTOR
public static final GraphQueue.AddUndirectedEdgeDescriptor ADD_UNDIRECTED_EDGE_DESCRIPTOR
CONNECT_DESCRIPTOR
public static final GraphQueue.ConnectDescriptor CONNECT_DESCRIPTOR
DELETE_EDGE_DESCRIPTOR
public static final GraphQueue.DeleteEdgeDescriptor DELETE_EDGE_DESCRIPTOR
DELETE_NODE_DESCRIPTOR
public static final GraphQueue.DeleteNodeDescriptor DELETE_NODE_DESCRIPTOR
EXECUTE_DESCRIPTOR
public static final GraphQueue.ExecuteDescriptor EXECUTE_DESCRIPTOR
FIRST_QUEUE
public static final QueueDescriptor FIRST_QUEUE
LAST_QUEUE
public static final QueueDescriptor LAST_QUEUE
GraphQueue
public GraphQueue(QueueDescriptor<?> descr,
boolean usesObjectQueue,
boolean createBackLinks)
addEdgeBits
public abstract void addEdgeBits(java.lang.Object source,
java.lang.Object target,
int edges)
addNode
public abstract void addNode(java.lang.Object node)
addUndirectedEdgeBits
public abstract void addUndirectedEdgeBits(java.lang.Object source,
java.lang.Object target,
int edges)
clear
public void clear()
- Description copied from interface:
Queue
- Clears the queue. This is invoked by the
QueueCollection
in order to reuse the queue for a new transformation step.
- Specified by:
clear
in interface Queue
- Overrides:
clear
in class HierarchicalQueue
clearSegmentsToExcludeImpl
protected void clearSegmentsToExcludeImpl(int[] segs)
connect
public abstract <N,P> void connect(N source,
N target,
P param,
Connector<N,P> redirector)
connectAdjacent
public abstract void connectAdjacent(java.lang.Object start,
java.lang.Object end,
int edges)
connectIncoming
public abstract <N> void connectIncoming(N source,
N target,
Operator<N> operator)
connectOutgoing
public abstract <N> void connectOutgoing(N source,
N target,
Operator<N> operator)
copyIncoming
public abstract void copyIncoming(java.lang.Object source,
java.lang.Object target,
int edges)
copyIncoming
public abstract void copyIncoming(java.lang.Object source,
java.lang.Object target,
int edges,
int copyMask,
int addMask)
copyOutgoing
public abstract void copyOutgoing(java.lang.Object source,
java.lang.Object target,
int edges)
copyOutgoing
public abstract void copyOutgoing(java.lang.Object source,
java.lang.Object target,
int edges,
int copyMask,
int addMask)
createProcessor
protected abstract GraphQueue.Processor createProcessor()
deleteCurrentEdges
public abstract void deleteCurrentEdges(java.lang.Object node,
int edges,
boolean outgoing)
deleteEdgeBits
public abstract void deleteEdgeBits(java.lang.Object source,
java.lang.Object target,
int edges)
deleteNode
public abstract void deleteNode(java.lang.Object node)
embedInterpretive
public abstract void embedInterpretive(java.lang.Object interpreted,
java.lang.Object start,
java.lang.Object end)
getDescriptor
public QueueDescriptor<?> getDescriptor()
- Description copied from interface:
Queue
- Returns the descriptor which was used to create this queue.
- Specified by:
getDescriptor
in interface Queue
- Returns:
- descriptor of this queue
- See Also:
QueueCollection.getQueue(QueueDescriptor)
,
QueueDescriptor.createQueue(QueueCollection)
getModel
protected abstract RuntimeModel getModel()
markSegment
public void markSegment(int n)
- Specified by:
markSegment
in interface Queue
moveIncoming
public abstract void moveIncoming(java.lang.Object source,
java.lang.Object target,
int edges)
moveOutgoing
public abstract void moveOutgoing(java.lang.Object source,
java.lang.Object target,
int edges)
process
public boolean process(int[] segments)
throws RuntimeModelException
- Description copied from interface:
Queue
- Processes all queued tasks. This method is invoked by
QueueCollection.process(int[])
.
- Specified by:
process
in interface Queue
- Returns:
true
iff the execution of tasks resulted
in modifications to the Graph
- Throws:
RuntimeModelException
- if some error occurs during execution
resetToSegment
public void resetToSegment(int n)
- Specified by:
resetToSegment
in interface Queue