pairwise-logo.gif (1266 bytes)

All Packages  Class Hierarchy  This Package  Previous  Next  Index

Class PairwiseComparativeMap.PairwiseComparativeMap

java.lang.Object
   |
   +----java.awt.Component
           |
           +----java.awt.Container
                   |
                   +----java.awt.Panel
                           |
                           +----PairwiseComparativeMap.PairwiseComparativeMap

public class PairwiseComparativeMap
extends Panel
implements ActionListener, AdjustmentListener, ComponentListener
This is the main class in the package. This class is called to create a PairwiseComparativeMap (PCM). Please see http://synteny.nott.ac.uk/software.html for more details on PCM, (if you haven't already come from there)!

You can either create a PCM with a blank constructor and feed in the data later, or do them both at the same time. A BeanInfo class is available for this class so you can use it in a Java IDE.

Version:
1.0

Author:
Written by Jeremy Dickson for the UK Crop Plant Bioinformatics Network, October 1998.

See Also:
PCM_FileParser, MultiPCM

Variable Index

 o FILE_PATH_TYPE_FILE
File path to parse is a local file.
 o FILE_PATH_TYPE_URL
File path to parse corresponds to a URL.

Constructor Index

 o PairwiseComparativeMap()
Default constructor.
 o PairwiseComparativeMap(String, int)
This constructor accepts a reference to a .pcm file and processes the data within to create the PCM.

Method Index

 o actionPerformed(ActionEvent)
 o addActionListener(ActionListener)
Add an action listener.
 o addData(PairwiseComparativeMapData, Array)
Add data to the component by passing in the preformed datastructure.
 o addData(String, int)
Add data to component via a PCM file.
 o adjustmentValueChanged(AdjustmentEvent)
This method is called when the user moves the scrollbar.
 o clickInAdjacentMap(String)
This is used by MultiPCM when there's been a click in an adjacent map to highlight any loci in this map of the same name.
 o componentAdded(ContainerEvent)
Not used.
 o componentHidden(ComponentEvent)
Not used.
 o componentMoved(ComponentEvent)
Not used.
 o componentRemoved(ContainerEvent)
Not used.
 o componentResized(ComponentEvent)
Used when the user resizes the component.
 o componentShown(ComponentEvent)
Not used.
 o getDatabaseColour_1()
Returns the colour that the sausages from the first database encountered in the data will be painted.
 o getDatabaseColour_2()
Returns the colour that the sausage from the second database encountered in the data will be painted.
 o getPCM_File()
Returns the file path or URL to the file that the component is to parse.
 o getPCMDataObject()
 o getSausageLength_LHS()
Returns the length of the chromosome on the default left-hand side of the map in units of pixels.
 o getSausageLength_RHS()
Returns the length of the chromosome on the default right-hand side of the map in units of pixels.
 o isCrossLinkToDatabase()
When set to true, a double-click on a locus will fire off an action event to component listeners containing the URL to the database..
 o jbInit()
This is a residual JBuilder class that sets up things like buttons etc.
 o processActionEvent(ActionEvent)
 o removeActionListener(ActionListener)
Remove an action listener.
 o setCrossLinkToDatabase(boolean)
When set to true, a double-click on a locus will fire off an action event to component listeners containing the URL to the database..
 o setDatabaseColour_1(Color)
Sets the colour that the sausages from the first database encountered in the data will be painted.
 o setDatabaseColour_2(Color)
Returns the colour that the sausage from the second database encountered in the data will be painted.
 o setPCM_File(String)
Sets the file path or URL to the file that the component is to parse.
 o setSausageColourToDatabase(String, Color)
This method can be called if you have a number of Pairwise maps linked together and you want to standardise the colours of the sausages for a particular database.
 o setSausageLength_LHS(int)
Sets the length of the chromosome on the default left-hand side of the map in units of pixels.
 o setSausageLength_RHS(int)
Sets the length of the chromosome on the default left-hand side of the map in units of pixels.

Variables

 o FILE_PATH_TYPE_FILE
 public static final int FILE_PATH_TYPE_FILE
File path to parse is a local file.

 o FILE_PATH_TYPE_URL
 public static final int FILE_PATH_TYPE_URL
File path to parse corresponds to a URL.

Constructors

 o PairwiseComparativeMap
 public PairwiseComparativeMap()
Default constructor.

 o PairwiseComparativeMap
 public PairwiseComparativeMap(String filePath,
                               int filePathType)
This constructor accepts a reference to a .pcm file and processes the data within to create the PCM.

Parameters:
filePath - A file path or URL to the .pcm file which you wish to use as a data source.
filePathType - This is an int that describes whether you wish to parse a file from a URL (1) or a file path from a local drive (0). You can use the variables FILE_PATH_TYPE_FILE and FILE_PATH_TYPE_URL for this purpose.

Methods

 o addData
 public void addData(String filePath,
                     int FilePathType)
Add data to component via a PCM file.

Parameters:
filePath - A file path or URL to the .pcm file which you wish to use as a data source.
filePathType - This is an int that describes whether you wish to parse a file from a URL (1) or a file path from a local drive (0). You can use the variables FILE_PATH_TYPE_FILE and FILE_PATH_TYPE_URL for this purpose.
 o addData
 public void addData(PairwiseComparativeMapData data,
                     Array homologys) throws PCMFileParsingException
Add data to the component by passing in the preformed datastructure. It is preferable to use a pcm file and the PCM_FileParser instead.

Parameters:
data - The data structure that the map uses.
homologys - An array of String[2] arrays describing the pairwise relationships. The string arrays should contain the names of a locus on either side of the map you wish to make a relationship between. Omit from the array any loci with no homolog on the other side.
 o setSausageColourToDatabase
 public void setSausageColourToDatabase(String databaseName,
                                        Color color)
This method can be called if you have a number of Pairwise maps linked together and you want to standardise the colours of the sausages for a particular database. Get a list of all the database names across the maps and then call this method in each map for every database name feeding in a different colour each time.

 o clickInAdjacentMap
 public void clickInAdjacentMap(String locusName)
This is used by MultiPCM when there's been a click in an adjacent map to highlight any loci in this map of the same name.

Parameters:
locusName - The name of the locus.
 o jbInit
 public void jbInit() throws Exception
This is a residual JBuilder class that sets up things like buttons etc. when the class is created. Who am I to delete it?!

 o actionPerformed
 public void actionPerformed(ActionEvent e)
 o adjustmentValueChanged
 public void adjustmentValueChanged(AdjustmentEvent parm1)
This method is called when the user moves the scrollbar.

 o componentAdded
 public void componentAdded(ContainerEvent parm1)
Not used.

 o componentRemoved
 public void componentRemoved(ContainerEvent parm1)
Not used.

 o componentResized
 public void componentResized(ComponentEvent parm1)
Used when the user resizes the component.

 o componentMoved
 public void componentMoved(ComponentEvent parm1)
Not used.

 o componentShown
 public void componentShown(ComponentEvent parm1)
Not used.

 o componentHidden
 public void componentHidden(ComponentEvent parm1)
Not used.

 o getPCMDataObject
 public PairwiseComparativeMapData getPCMDataObject()
 o getDatabaseColour_1
 public Color getDatabaseColour_1()
Returns the colour that the sausages from the first database encountered in the data will be painted.

 o setDatabaseColour_1
 public void setDatabaseColour_1(Color databaseColour_1)
Sets the colour that the sausages from the first database encountered in the data will be painted.

 o getDatabaseColour_2
 public Color getDatabaseColour_2()
Returns the colour that the sausage from the second database encountered in the data will be painted.

 o setDatabaseColour_2
 public void setDatabaseColour_2(Color databaseColour_2)
Returns the colour that the sausage from the second database encountered in the data will be painted.

 o getPCM_File
 public String getPCM_File()
Returns the file path or URL to the file that the component is to parse.

 o setPCM_File
 public void setPCM_File(String PCM_File)
Sets the file path or URL to the file that the component is to parse.

 o isCrossLinkToDatabase
 public boolean isCrossLinkToDatabase()
When set to true, a double-click on a locus will fire off an action event to component listeners containing the URL to the database..

 o setCrossLinkToDatabase
 public void setCrossLinkToDatabase(boolean crossLinkToDatabase)
When set to true, a double-click on a locus will fire off an action event to component listeners containing the URL to the database..

 o getSausageLength_LHS
 public int getSausageLength_LHS()
Returns the length of the chromosome on the default left-hand side of the map in units of pixels.

 o setSausageLength_LHS
 public void setSausageLength_LHS(int sausageLength_LHS)
Sets the length of the chromosome on the default left-hand side of the map in units of pixels.

 o getSausageLength_RHS
 public int getSausageLength_RHS()
Returns the length of the chromosome on the default right-hand side of the map in units of pixels.

 o setSausageLength_RHS
 public void setSausageLength_RHS(int sausageLength_RHS)
Sets the length of the chromosome on the default left-hand side of the map in units of pixels.

 o addActionListener
 public synchronized void addActionListener(ActionListener l)
Add an action listener.

 o removeActionListener
 public synchronized void removeActionListener(ActionListener l)
Remove an action listener.

 o processActionEvent
 protected void processActionEvent(ActionEvent e)

All Packages  Class Hierarchy  This Package  Previous  Next  Index