uk.ac.man.bioinf.apps.cinema
Class CinemaModule

java.lang.Object
  |
  +--uk.ac.man.bioinf.module.Module
        |
        +--uk.ac.man.bioinf.apps.xml.XMLModule
              |
              +--uk.ac.man.bioinf.apps.cinema.CinemaModule
All Implemented Interfaces:
AlignmentEventProvider
Direct Known Subclasses:
CinemaColorFactory, CinemaCommandLineParser, CinemaConsensus, CinemaGroupModule, CinemaGuiModule, CinemaMenuBuilder, CinemaMotifModule, CinemaMultipleConsensusViewer, CinemaPersist, CinemaRegexp, CinemaResizeElements, CinemaSlaveViewerModule, CinemaSplash

public abstract class CinemaModule
extends XMLModule
implements AlignmentEventProvider

CinemaModule.java Most modules for Cinema should extend this interface. It provides access to most of the functions of Cinema without being to tied to the main GUI components, which should insulate these modules from any changes which are made to it. I intend to include a few other methods here. I think that the CinemaModule should provide access to listeners for the cursor for instance, as this is a concept relatively divorced from that of the GUI. Created: Fri May 26 16:04:49 2000

Version:
$Id: CinemaModule.java,v 1.7 2001/04/11 17:04:41 lord Exp $
Author:
Phillip Lord

Constructor Summary
CinemaModule()
           
 
Method Summary
 void addAlignmentListener(AlignmentListener listener)
          Add a listener specifically interested in events connected with the MSA.
 void addCinemaPropertyChangeListener(PropertyChangeListener listener)
           
 void addCinemaPropertyChangeListener(String propertyName, PropertyChangeListener listener)
           
 void addVetoableAlignmentListener(VetoableAlignmentListener listener)
          Adds a listener interested in vetoing multiple sequence alignment specific events.
 void clearSequenceTitleColor(GappedSequence seq)
           
 void destroy()
          The method called, from an external source, to remove this module and prepare it for garbage collection.
 void fireCinemaPropertyChange(String name, Object old, Object newV)
           
 AlignmentSelectionModel getAlignmentSelectionModel()
           
 ColorMap getColorMap()
           
 ModuleIdentifierList getRequiredIdentifiers()
          Returns the module identifiers for the required modules.
 SequenceAlignment getSequenceAlignment()
           
 void removeAlignmentListener(AlignmentListener listener)
          Removes a multiple sequence alignment listener.
 void removeCinemaPropertyChangeListener(PropertyChangeListener listener)
           
 void removeCinemaPropertyChangeListener(String propertyName, PropertyChangeListener listener)
           
 void removeVetoableAlignmentListener(VetoableAlignmentListener listener)
          Removes a vetoable multiple sequence alignment listener.
 void sendStatusMessage(String message)
           
 void setAlignmentSelectionModel(AlignmentSelectionModel model)
           
 void setColorMap(ColorMap map)
           
 void setSequenceAlignment(SequenceAlignment seq)
          Set the Sequence Alignment.
 void setSequenceTitleColor(GappedSequence seq, Color colour)
          This sets the colour that is used to display the sequence title.
 
Methods inherited from class uk.ac.man.bioinf.apps.xml.XMLModule
getConfigProperties, getConfigTree
 
Methods inherited from class uk.ac.man.bioinf.module.Module
addPropertyChangeListener, addPropertyChangeListener, finalize, firePropertyChange, firePropertyChange, firePropertyChange, getContext, getIdentifier, getRequiredModule, getRequiredModules, getVersion, hasListeners, isDestroyed, isStarted, load, removePropertyChangeListener, removePropertyChangeListener, runStart, setContext, start
 
Methods inherited from class java.lang.Object
clone, equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

CinemaModule

public CinemaModule()
Method Detail

getSequenceAlignment

public SequenceAlignment getSequenceAlignment()

setSequenceAlignment

public void setSequenceAlignment(SequenceAlignment seq)
Set the Sequence Alignment. Signals a property change event.

Parameters:
seq -

getColorMap

public ColorMap getColorMap()

setColorMap

public void setColorMap(ColorMap map)

getAlignmentSelectionModel

public AlignmentSelectionModel getAlignmentSelectionModel()

setAlignmentSelectionModel

public void setAlignmentSelectionModel(AlignmentSelectionModel model)

setSequenceTitleColor

public void setSequenceTitleColor(GappedSequence seq,
                                  Color colour)
This sets the colour that is used to display the sequence title. NOT the colour of the elements! This is usually done to display some linkage between sequences of the same colour.

Parameters:
seq -
colour -

clearSequenceTitleColor

public void clearSequenceTitleColor(GappedSequence seq)

sendStatusMessage

public void sendStatusMessage(String message)

fireCinemaPropertyChange

public void fireCinemaPropertyChange(String name,
                                     Object old,
                                     Object newV)

addCinemaPropertyChangeListener

public void addCinemaPropertyChangeListener(PropertyChangeListener listener)

removeCinemaPropertyChangeListener

public void removeCinemaPropertyChangeListener(PropertyChangeListener listener)

addCinemaPropertyChangeListener

public void addCinemaPropertyChangeListener(String propertyName,
                                            PropertyChangeListener listener)

removeCinemaPropertyChangeListener

public void removeCinemaPropertyChangeListener(String propertyName,
                                               PropertyChangeListener listener)

addAlignmentListener

public void addAlignmentListener(AlignmentListener listener)
Description copied from interface: AlignmentEventProvider
Add a listener specifically interested in events connected with the MSA.

Specified by:
addAlignmentListener in interface AlignmentEventProvider
Parameters:
listener - a multiple sequence alignment listener

removeAlignmentListener

public void removeAlignmentListener(AlignmentListener listener)
Description copied from interface: AlignmentEventProvider
Removes a multiple sequence alignment listener.

Specified by:
removeAlignmentListener in interface AlignmentEventProvider
Parameters:
listener - the listener to be removed

addVetoableAlignmentListener

public void addVetoableAlignmentListener(VetoableAlignmentListener listener)
Description copied from interface: AlignmentEventProvider
Adds a listener interested in vetoing multiple sequence alignment specific events.

Specified by:
addVetoableAlignmentListener in interface AlignmentEventProvider
Parameters:
listener - a vetoable multiple sequence alignment listener

removeVetoableAlignmentListener

public void removeVetoableAlignmentListener(VetoableAlignmentListener listener)
Description copied from interface: AlignmentEventProvider
Removes a vetoable multiple sequence alignment listener.

Specified by:
removeVetoableAlignmentListener in interface AlignmentEventProvider
Parameters:
listener - the listener to be removed

destroy

public void destroy()
Description copied from class: Module
The method called, from an external source, to remove this module and prepare it for garbage collection.

Overrides:
destroy in class Module

getRequiredIdentifiers

public ModuleIdentifierList getRequiredIdentifiers()
Description copied from class: Module
Returns the module identifiers for the required modules. This places a call on getRequiredModules, which is delegated to the module context. It may require over-riding inorder to improve the efficiency of the method.

Overrides:
getRequiredIdentifiers in class Module
Returns:
the required module identifiers