org.wilmascope.view
Class ViewManager
java.lang.Object
org.wilmascope.view.ViewManager
public class ViewManager
- extends java.lang.Object
This class manages a 'registry' of view object prototypes for
nodes and edges. It implements the 'Singleton' pattern to ensure that
only one instance is available to the System, a reference to which may
be obtained using the getInstance()
method.
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
getInstance
public static ViewManager getInstance()
- Returns:
- a reference to the Singleton instance of this class.
loadViews
public void loadViews()
throws java.io.IOException,
java.lang.ClassNotFoundException,
java.lang.IllegalAccessException,
java.lang.InstantiationException
- Throws:
java.io.IOException
java.lang.ClassNotFoundException
java.lang.IllegalAccessException
java.lang.InstantiationException
addPrototypeView
public void addPrototypeView(GraphElementView view)
getNodeViewRegistry
public ViewManager.Registry getNodeViewRegistry()
getEdgeViewRegistry
public ViewManager.Registry getEdgeViewRegistry()
getClusterViewRegistry
public ViewManager.Registry getClusterViewRegistry()
createClusterView
public ClusterView createClusterView(java.lang.String type)
throws ViewManager.UnknownViewTypeException
- Throws:
ViewManager.UnknownViewTypeException
createNodeView
public NodeView createNodeView(java.lang.String type)
throws ViewManager.UnknownViewTypeException
- Throws:
ViewManager.UnknownViewTypeException
createEdgeView
public EdgeView createEdgeView(java.lang.String type)
throws ViewManager.UnknownViewTypeException
- Throws:
ViewManager.UnknownViewTypeException
createClusterView
public ClusterView createClusterView()
throws ViewManager.UnknownViewTypeException
- Throws:
ViewManager.UnknownViewTypeException
createNodeView
public NodeView createNodeView()
throws ViewManager.UnknownViewTypeException
- Throws:
ViewManager.UnknownViewTypeException
createEdgeView
public EdgeView createEdgeView()
throws ViewManager.UnknownViewTypeException
- Throws:
ViewManager.UnknownViewTypeException
getDefaultEdgeViewType
public java.lang.String getDefaultEdgeViewType()
getDefaultNodeViewType
public java.lang.String getDefaultNodeViewType()
getDefaultClusterViewType
public java.lang.String getDefaultClusterViewType()