jp.sbi.celldesigner.plugin
Class CellDesignerPlugin

java.lang.Object
  extended by jp.sbi.celldesigner.plugin.CellDesignerPlugin
All Implemented Interfaces:
CellDesignerPlug

public abstract class CellDesignerPlugin
extends java.lang.Object
implements CellDesignerPlug

Interface class of CellDesignerPlugin.

Author:

Constructor Summary
CellDesignerPlugin()
           
 
Method Summary
 void addCellDesignerPluginMenu(PluginMenu menu)
          Adds the menu for this plug-in to CellDesigner.
 void addCompartmentPopupMenu(PluginMenu menu)
          Adds the compartment popup menu to CellDesigner.
 void addCompartmentPopupMenuSeparator()
          Adds the boundary to the compartment popup menu of CellDesigner.
 void addReactionPopupMenu(PluginMenu menu)
          Adds the reaction popup menu to CellDesigner.
 void addReactionPopupMenuSeparator()
          Adds the boundary to the reaction popup menu of CellDesigner.
 void addSpeciesPopupMenu(PluginMenu menu)
          Adds the species popup menu to CellDesigner.
 void addSpeciesPopupMenuSeparator()
          Adds the boundary to the species popup menu of CellDesigner.
 boolean cloneCurrModel()
           
protected  java.lang.String createNewAliasId()
          Create NewAliasId
protected  java.lang.String createNewCompartmentId()
          Creates NewCompartmentId
protected  java.lang.String createNewReactionId()
          Creates NewReactionId
protected  java.lang.String createNewSpeciesId()
          Creates NewSpeciesId
 boolean doCircularLayout()
           
 boolean exportDrawAreaToImageFile(java.lang.String strOutputFileDirName, java.lang.String strOutputFileName, java.lang.String strOutputFileExtention)
           
 PluginListOf getAllModels()
          Deprecated. 
 PluginListOf getAllSpeciesNodes()
           
 PluginModel getModel(java.lang.String id)
           
 PluginListOf getSelectedAllNode()
           
 PluginListOf getSelectedAllNode(PluginModel pluginModel)
           
 PluginListOf getSelectedCompartmentNode()
           
 PluginListOf getSelectedCompartmentNode(PluginModel pluginModel)
           
 PluginModel getSelectedModel()
           
 PluginListOf getSelectedReactionNode()
           
 PluginListOf getSelectedReactionNode(PluginModel pluginModel)
           
 PluginListOf getSelectedSpeciesNode()
           
 PluginListOf getSelectedSpeciesNode(PluginModel pluginModel)
           
 boolean isStarted()
           
 void modelClosed(SBase sbase)
          Called when Model is closed on CellDesigner.
 void modelOpened(SBase sbase)
          Called when Model is opened on CellDesigner.
 void modelSelectChanged(SBase sbase)
          Called when the selected Model is changed on CellDesigner.
 boolean notifySBaseAdded(PluginSBase sbase)
          notifySBaseAdded
 boolean notifySBaseChanged(PluginSBase sbase)
          notifySBaseChanged
 boolean notifySBaseDeleted(PluginSBase sbase)
          notifySBaseDeleted
 void SBaseAdded(SBase sbase)
          Called when a PluginSBase is added on CellDesigner.
 void SBaseAdded(jp.sbi.celldesigner.SpeciesAlias sbase, Species parent)
          Called when SBase is added on CellDesigner.
 void SBaseChanged(SBase sbase)
          Called when some properties of PluginSBase are changed on CellDesigner.
 void SBaseChanged(jp.sbi.celldesigner.SpeciesAlias sbase, Species parent)
          Called when some properties of SBase are changed on CellDesigner.
 void SBaseDeleted(SBase sbase)
          Called when PluginSBase is deleted on CellDesigner.
 void SBaseDeleted(jp.sbi.celldesigner.SpeciesAlias sbase, Species parent)
          Called when SBase is deleted on CellDesigner.
 boolean SBaseSelected()
           
 void setStarted(boolean isStarted)
          Sets the start flag
Note: Set true if a plugin is invoked.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface jp.sbi.celldesigner.plugin.CellDesignerPlug
addPluginMenu
 

Constructor Detail

CellDesignerPlugin

public CellDesignerPlugin()
Method Detail

addCellDesignerPluginMenu

public void addCellDesignerPluginMenu(PluginMenu menu)
Adds the menu for this plug-in to CellDesigner.

Parameters:
PluginMenu -

addSpeciesPopupMenu

public void addSpeciesPopupMenu(PluginMenu menu)
Adds the species popup menu to CellDesigner.

Parameters:
PluginMenu -

addSpeciesPopupMenuSeparator

public void addSpeciesPopupMenuSeparator()
Adds the boundary to the species popup menu of CellDesigner.


addReactionPopupMenu

public void addReactionPopupMenu(PluginMenu menu)
Adds the reaction popup menu to CellDesigner.

Parameters:
PluginMenu -

addReactionPopupMenuSeparator

public void addReactionPopupMenuSeparator()
Adds the boundary to the reaction popup menu of CellDesigner.


addCompartmentPopupMenu

public void addCompartmentPopupMenu(PluginMenu menu)
Adds the compartment popup menu to CellDesigner.

Parameters:
PluginMenu -

addCompartmentPopupMenuSeparator

public void addCompartmentPopupMenuSeparator()
Adds the boundary to the compartment popup menu of CellDesigner.


getSelectedModel

public PluginModel getSelectedModel()
Returns:
The model selected on CellDesigner

getModel

public PluginModel getModel(java.lang.String id)
Returns:
the model with the given id or null if no such model exists.

getAllModels

@Deprecated
public PluginListOf getAllModels()
Deprecated. 

Returns:
the list of all models opened on CellDesigner.

getSelectedSpeciesNode

public PluginListOf getSelectedSpeciesNode()
Returns:
the list of species selected on CellDesigner.

getSelectedSpeciesNode

public PluginListOf getSelectedSpeciesNode(PluginModel pluginModel)
Parameters:
pluginModel -
Returns:
the list of species selected on celldesigner

getAllSpeciesNodes

public PluginListOf getAllSpeciesNodes()
Returns:
the list of all species selected on CellDesigner.

getSelectedReactionNode

public PluginListOf getSelectedReactionNode()
Returns:
the list of reactions selected on CellDesigner.

getSelectedReactionNode

public PluginListOf getSelectedReactionNode(PluginModel pluginModel)
Parameters:
pluginModel -
Returns:
the list of reactions selected on CellDesigner.

getSelectedCompartmentNode

public PluginListOf getSelectedCompartmentNode()
Returns:
the list of compartments selected on CellDesigner.

getSelectedCompartmentNode

public PluginListOf getSelectedCompartmentNode(PluginModel pluginModel)
Parameters:
pluginModel -
Returns:
the list of compartments selected on CellDesigner.

getSelectedAllNode

public PluginListOf getSelectedAllNode()
Returns:
the list of all nodes selected on CellDesigner.

getSelectedAllNode

public PluginListOf getSelectedAllNode(PluginModel pluginModel)
Parameters:
pluginModel -
Returns:
the list of all nodes selected on CellDesigner

createNewSpeciesId

protected java.lang.String createNewSpeciesId()
Creates NewSpeciesId

Returns:
the new species id, or NULL if model is null.

createNewCompartmentId

protected java.lang.String createNewCompartmentId()
Creates NewCompartmentId

Returns:
the new compartment id

createNewReactionId

protected java.lang.String createNewReactionId()
Creates NewReactionId

Returns:
the new reaction id

createNewAliasId

protected java.lang.String createNewAliasId()
Create NewAliasId

Returns:
the new alias id

SBaseAdded

public void SBaseAdded(SBase sbase)
Description copied from interface: CellDesignerPlug
Called when a PluginSBase is added on CellDesigner.

Specified by:
SBaseAdded in interface CellDesignerPlug
Parameters:
sbase -

SBaseAdded

public void SBaseAdded(jp.sbi.celldesigner.SpeciesAlias sbase,
                       Species parent)
Description copied from interface: CellDesignerPlug
Called when SBase is added on CellDesigner.

Specified by:
SBaseAdded in interface CellDesignerPlug
Parameters:
sbase -
parent -

SBaseChanged

public void SBaseChanged(SBase sbase)
Description copied from interface: CellDesignerPlug
Called when some properties of PluginSBase are changed on CellDesigner.

Specified by:
SBaseChanged in interface CellDesignerPlug
Parameters:
sbase -

SBaseChanged

public void SBaseChanged(jp.sbi.celldesigner.SpeciesAlias sbase,
                         Species parent)
Description copied from interface: CellDesignerPlug
Called when some properties of SBase are changed on CellDesigner.

Specified by:
SBaseChanged in interface CellDesignerPlug
Parameters:
sbase -
parent -

SBaseDeleted

public void SBaseDeleted(SBase sbase)
Description copied from interface: CellDesignerPlug
Called when PluginSBase is deleted on CellDesigner.

Specified by:
SBaseDeleted in interface CellDesignerPlug
Parameters:
sbase -

SBaseDeleted

public void SBaseDeleted(jp.sbi.celldesigner.SpeciesAlias sbase,
                         Species parent)
Description copied from interface: CellDesignerPlug
Called when SBase is deleted on CellDesigner.

Specified by:
SBaseDeleted in interface CellDesignerPlug
Parameters:
sbase -
parent -

modelOpened

public void modelOpened(SBase sbase)
Description copied from interface: CellDesignerPlug
Called when Model is opened on CellDesigner.

Specified by:
modelOpened in interface CellDesignerPlug
Parameters:
sbase -

modelSelectChanged

public void modelSelectChanged(SBase sbase)
Description copied from interface: CellDesignerPlug
Called when the selected Model is changed on CellDesigner.

Specified by:
modelSelectChanged in interface CellDesignerPlug
Parameters:
sbase -

modelClosed

public void modelClosed(SBase sbase)
Description copied from interface: CellDesignerPlug
Called when Model is closed on CellDesigner.

Specified by:
modelClosed in interface CellDesignerPlug
Parameters:
sbase -

notifySBaseAdded

public boolean notifySBaseAdded(PluginSBase sbase)
notifySBaseAdded

Specified by:
notifySBaseAdded in interface CellDesignerPlug
Parameters:
sbase -

notifySBaseChanged

public boolean notifySBaseChanged(PluginSBase sbase)
notifySBaseChanged

Specified by:
notifySBaseChanged in interface CellDesignerPlug
Parameters:
sbase -

notifySBaseDeleted

public boolean notifySBaseDeleted(PluginSBase sbase)
notifySBaseDeleted

Specified by:
notifySBaseDeleted in interface CellDesignerPlug
Parameters:
sbase -

isStarted

public boolean isStarted()
Specified by:
isStarted in interface CellDesignerPlug
Returns:
true if this plugin is starting, false otherwise.

setStarted

public void setStarted(boolean isStarted)
Sets the start flag
Note: Set true if a plugin is invoked. If the parameter is false, the plugin can't receive any events from CellDesigner, or call the follwing methods:
 SBaseAdded(PluginSBase)
 SBaseChanged(PluginSBase)
 SBaseDeleted(PluginSBase)
 modelOpened(PluginSBase)
 modelSelectChanged(PluginSBase)
 modelClosed(PluginSBase)
 

Parameters:
true - if plug is starting, false otherwise.

exportDrawAreaToImageFile

public boolean exportDrawAreaToImageFile(java.lang.String strOutputFileDirName,
                                         java.lang.String strOutputFileName,
                                         java.lang.String strOutputFileExtention)

doCircularLayout

public boolean doCircularLayout()

cloneCurrModel

public boolean cloneCurrModel()

SBaseSelected

public boolean SBaseSelected()
Specified by:
SBaseSelected in interface CellDesignerPlug