public class Timeline extends Object implements Source, Replayable, Iterable<Graph>
Modifier and Type | Class and Description |
---|---|
protected class |
Timeline.Connector |
private class |
Timeline.StepDiff |
protected class |
Timeline.TimelineIterator |
protected class |
Timeline.TimelineReplayController |
Replayable.Controller
Modifier and Type | Field and Description |
---|---|
protected boolean |
changed |
protected Timeline.Connector |
connector |
protected GraphDiff |
currentDiff |
protected Graph |
currentGraph |
(package private) LinkedList<Timeline.StepDiff> |
diffs |
protected Graph |
initialGraph |
protected PipeBase |
pipe |
protected int |
seeker |
static String |
TIME_PREFIX |
Constructor and Description |
---|
Timeline() |
Modifier and Type | Method and Description |
---|---|
void |
addAttributeSink(AttributeSink sink)
Add a sink for attribute events only.
|
void |
addElementSink(ElementSink sink)
Add a sink for elements events only.
|
void |
addSink(Sink sink)
Add a sink for all graph events (attributes and graph elements) coming
from this source.
|
protected void |
begin() |
void |
begin(Graph source) |
void |
begin(Source source) |
void |
clearAttributeSinks()
Remove all listener attribute sinks.
|
void |
clearElementSinks()
Remove all listener element sinks.
|
void |
clearSinks()
Remove all listener sinks.
|
void |
end() |
Replayable.Controller |
getReplayController()
Get a controller to replay the graph.
|
boolean |
hasNext() |
boolean |
hasPrevious() |
Iterator<Graph> |
iterator() |
static void |
main(String... strings) |
void |
next() |
void |
play() |
void |
play(double from,
double to) |
void |
play(double from,
double to,
Sink sink) |
void |
play(Sink sink) |
void |
playback() |
void |
playback(Sink sink) |
void |
previous() |
protected void |
pushDiff() |
void |
removeAttributeSink(AttributeSink sink)
Remove an attribute sink.
|
void |
removeElementSink(ElementSink sink)
Remove an element sink.
|
void |
removeSink(Sink sink)
Remove a sink.
|
void |
reset() |
void |
seek(int i) |
void |
seekEnd() |
void |
seekStart() |
private static String |
toString(Graph g) |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
forEach, spliterator
public static final String TIME_PREFIX
LinkedList<Timeline.StepDiff> diffs
protected boolean changed
protected Graph initialGraph
protected Graph currentGraph
protected GraphDiff currentDiff
protected Timeline.Connector connector
protected int seeker
public Timeline()
public void reset()
public void play(double from, double to)
public void play()
public void playback()
public void seek(int i)
public void seekStart()
public void seekEnd()
public boolean hasNext()
public void next()
public boolean hasPrevious()
public void previous()
protected void begin()
public void end()
protected void pushDiff()
public Replayable.Controller getReplayController()
Replayable
getReplayController
in interface Replayable
public void addSink(Sink sink)
Source
public void removeSink(Sink sink)
Source
removeSink
in interface Source
sink
- The sink to remove, if it does not exist, this is ignored
silently.public void addAttributeSink(AttributeSink sink)
Source
addAttributeSink
in interface Source
sink
- The sink to register.public void removeAttributeSink(AttributeSink sink)
Source
removeAttributeSink
in interface Source
sink
- The sink to remove, if it does not exist, this is ignored
silently.public void addElementSink(ElementSink sink)
Source
addElementSink
in interface Source
sink
- The sink to register.public void removeElementSink(ElementSink sink)
Source
removeElementSink
in interface Source
sink
- The sink to remove, if it does not exist, this is ignored
silently.public void clearElementSinks()
Source
clearElementSinks
in interface Source
public void clearAttributeSinks()
Source
clearAttributeSinks
in interface Source
public void clearSinks()
Source
clearSinks
in interface Source
WebARTS Library Licensed Under the GNU - General Public License. Other Libraries licensed under their respective Open Source Licenses