Package org.graphstream.stream
Class SourceAdapter
java.lang.Object
org.graphstream.stream.SourceAdapter
- All Implemented Interfaces:
Source
public class SourceAdapter extends Object implements Source
Adapter for the input interface.
All methods are empty.
-
Constructor Summary
Constructors Constructor Description SourceAdapter() -
Method Summary
Modifier and Type Method Description voidaddAttributeSink(AttributeSink sink)Add a sink for attribute events only.voidaddElementSink(ElementSink sink)Add a sink for elements events only.voidaddSink(Sink sink)Add a sink for all graph events (attributes and graph elements) coming from this source.voidclearAttributeSinks()Remove all listener attribute sinks.voidclearElementSinks()Remove all listener element sinks.voidclearSinks()Remove all listener sinks.voidremoveAttributeSink(AttributeSink sink)Remove an attribute sink.voidremoveElementSink(ElementSink sink)Remove an element sink.voidremoveSink(Sink sink)Remove a sink.
-
Constructor Details
-
SourceAdapter
public SourceAdapter()
-
-
Method Details
-
addAttributeSink
Description copied from interface:SourceAdd a sink for attribute events only. Attribute events include attribute addition change and removal.- Specified by:
addAttributeSinkin interfaceSource- Parameters:
sink- The sink to register.
-
addElementSink
Description copied from interface:SourceAdd a sink for elements events only. Elements events include, addition and removal of nodes and edges, as well as step events.- Specified by:
addElementSinkin interfaceSource- Parameters:
sink- The sink to register.
-
addSink
Description copied from interface:SourceAdd a sink for all graph events (attributes and graph elements) coming from this source. This is similar to registering a sink for attributes an another for elements. -
removeAttributeSink
Description copied from interface:SourceRemove an attribute sink.- Specified by:
removeAttributeSinkin interfaceSource- Parameters:
sink- The sink to remove, if it does not exist, this is ignored silently.
-
removeElementSink
Description copied from interface:SourceRemove an element sink.- Specified by:
removeElementSinkin interfaceSource- Parameters:
sink- The sink to remove, if it does not exist, this is ignored silently.
-
removeSink
Description copied from interface:SourceRemove a sink.- Specified by:
removeSinkin interfaceSource- Parameters:
sink- The sink to remove, if it does not exist, this is ignored silently.
-
clearAttributeSinks
public void clearAttributeSinks()Description copied from interface:SourceRemove all listener attribute sinks.- Specified by:
clearAttributeSinksin interfaceSource
-
clearElementSinks
public void clearElementSinks()Description copied from interface:SourceRemove all listener element sinks.- Specified by:
clearElementSinksin interfaceSource
-
clearSinks
public void clearSinks()Description copied from interface:SourceRemove all listener sinks.- Specified by:
clearSinksin interfaceSource
-