JAL-1807 Bob's JalviewJS prototype first commit
[jalviewjs.git] / src / jalview / structure / CommandListener.java
1 package jalview.structure;
2
3 import jalview.commands.CommandI;
4
5 /**
6  * Defines a listener for commands performed on another alignment. This is to
7  * support linked editing of two alternative representations of an alignment (in
8  * particular, cDNA and protein).
9  * 
10  * @author gmcarstairs
11  *
12  */
13 public interface CommandListener
14 {
15   /**
16    * The listener may attempt to perform the specified command; the region acted
17    * on is determined by a callback to the StructureSelectionManager (which
18    * holds mappings between alignments).
19    * 
20    * @param command
21    * @param undo
22    * @param ssm
23    * @param source
24    *          the originator of the command
25    */
26   public void mirrorCommand(CommandI command, boolean undo,
27           StructureSelectionManager ssm, VamsasSource source);
28
29   /**
30    * Temporary workaround to make check for source == listener work.
31    * 
32    * @return
33    */
34   public VamsasSource getVamsasSource();
35 }