|
Cytoscape 2.8.2 API | |||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectcytoscape.layout.AbstractLayout
public abstract class AbstractLayout
The AbstractLayout provides nice starting point for Layouts written for Cytoscape.
| Field Summary | |
|---|---|
protected boolean |
canceled
|
protected Dimension |
currentSize
|
protected String |
edgeAttribute
|
protected CyNetwork |
network
|
protected CyNetworkView |
networkView
|
protected String |
nodeAttribute
|
protected static TaskMonitor |
nullTaskMonitor
|
protected HashMap |
propertyMap
|
protected String |
propertyPrefix
|
protected HashMap |
savedPropertyMap
|
protected boolean |
selectedOnly
|
protected Set<NodeView> |
staticNodes
|
protected TaskMonitor |
taskMonitor
|
| Constructor Summary | |
|---|---|
AbstractLayout()
The Constructor is null |
|
| Method Summary | |
|---|---|
abstract void |
construct()
These abstract methods must be overridden. |
void |
doLayout()
doLayout on current network view. |
void |
doLayout(CyNetworkView nview)
doLayout on specified network view. |
void |
doLayout(CyNetworkView nview,
TaskMonitor monitor)
doLayout on specified network view with specified monitor. |
List<String> |
getInitialAttributeList()
This returns the list of "attributes" that are provided by an algorithm for internal purposes. |
abstract String |
getName()
getName is used to construct property strings for this layout. |
LayoutProperties |
getSettings()
Property handling -- these must be overridden by any algorithms that want to use properties or have a settings UI. |
JPanel |
getSettingsPanel()
Returns a JPanel to be used as part of the Settings dialog for this layout algorithm. |
void |
halt()
Halt the algorithm. |
protected void |
initialize_local()
Initializes all local information, and is called immediately within the initialize() process. |
void |
initialize()
Initializer, calls intialize_local to start construction process. |
protected boolean |
isLocked(NodeView v)
|
void |
lockNode(NodeView v)
Lock this node (i.e. |
void |
lockNodes(NodeView[] nodes)
Lock these nodes (i.e. |
protected void |
resetLabelPositions()
Deletes labelPosition attribute of selected nodes (if selectedOnly) or all nodes This has the effect of moving labels back to their parent nodes position |
void |
revertSettings()
Property handling -- these must be overridden by any algorithms that want to use properties or have a settings UI. |
void |
setLayoutAttribute(String attributeName)
Set the name of the attribute to use for attribute dependent layout algorithms. |
void |
setSelectedOnly(boolean selectedOnly)
Set the flag that indicates that this algorithm should only operate on the currently selected nodes. |
byte[] |
supportsEdgeAttributes()
Returns the types of edge attributes supported by this algorithm. |
byte[] |
supportsNodeAttributes()
Returns the types of node attributes supported by this algorithm. |
boolean |
supportsSelectedOnly()
These methods should be overridden |
abstract String |
toString()
toString is used to get the user-visible name of the layout |
void |
unlockAllNodes()
Unlock all nodes |
void |
unlockNode(NodeView v)
Unlock this node |
void |
updateSettings()
Property handling -- these must be overridden by any algorithms that want to use properties or have a settings UI. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Field Detail |
|---|
protected Set<NodeView> staticNodes
protected CyNetworkView networkView
protected CyNetwork network
protected boolean selectedOnly
protected String edgeAttribute
protected String nodeAttribute
protected boolean canceled
protected Dimension currentSize
protected HashMap propertyMap
protected HashMap savedPropertyMap
protected TaskMonitor taskMonitor
protected static TaskMonitor nullTaskMonitor
protected String propertyPrefix
| Constructor Detail |
|---|
public AbstractLayout()
| Method Detail |
|---|
public abstract void construct()
public abstract String getName()
getName in interface CyLayoutAlgorithmpublic abstract String toString()
toString in class Objectpublic boolean supportsSelectedOnly()
supportsSelectedOnly in interface CyLayoutAlgorithmpublic void setSelectedOnly(boolean selectedOnly)
setSelectedOnly in interface CyLayoutAlgorithmselectedOnly - set to "true" if the algorithm should
only apply to selected nodes onlypublic byte[] supportsNodeAttributes()
supportsNodeAttributes in interface CyLayoutAlgorithmpublic byte[] supportsEdgeAttributes()
supportsEdgeAttributes in interface CyLayoutAlgorithmpublic void setLayoutAttribute(String attributeName)
setLayoutAttribute in interface CyLayoutAlgorithmattributeName - The name of the attributepublic List<String> getInitialAttributeList()
getInitialAttributeList in interface CyLayoutAlgorithmpublic JPanel getSettingsPanel()
getSettingsPanel in interface CyLayoutAlgorithmpublic void revertSettings()
revertSettings in interface CyLayoutAlgorithmpublic void updateSettings()
updateSettings in interface CyLayoutAlgorithmpublic LayoutProperties getSettings()
getSettings in interface CyLayoutAlgorithmpublic void doLayout()
doLayout in interface CyLayoutAlgorithmpublic void doLayout(CyNetworkView nview)
doLayout in interface CyLayoutAlgorithmnview - the CyNetworkView on which to perform the layout
public void doLayout(CyNetworkView nview,
TaskMonitor monitor)
doLayout in interface CyLayoutAlgorithmnview - the CyNetworkView on which to perform the layoutmonitor - the task monitor to usepublic void initialize()
protected void initialize_local()
public void lockNodes(NodeView[] nodes)
lockNodes in interface CyLayoutAlgorithmnodes - An array of NodeView's to lockpublic void lockNode(NodeView v)
lockNode in interface CyLayoutAlgorithmv - A NodeView to lockpublic void unlockNode(NodeView v)
unlockNode in interface CyLayoutAlgorithmv - A NodeView to unlockprotected boolean isLocked(NodeView v)
public void unlockAllNodes()
unlockAllNodes in interface CyLayoutAlgorithmpublic void halt()
halt in interface CyLayoutAlgorithmprotected void resetLabelPositions()
|
Cytoscape 2.8.2 API | |||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||