Class MySaveFileListener
java.lang.Object
org.biojava.nbio.structure.align.gui.MySaveFileListener
- All Implemented Interfaces:
ActionListener
,EventListener
Save an alignment to a specified File by the user. The alignment to be
saved depends on the constructor used to instantiate this class, so that
AFPChains and MultipleAlignments can be saved.
The format to save the alignment depends on the Frame that generated the Action: from a sequence alignment a FatCat or FASTA formats are saved, and from a Jmol view an XML format is saved.
- Version:
- 2.0 - adapted for MultipleAligments
- Author:
- Aleix Lafita
-
Constructor Summary
ConstructorDescriptionMySaveFileListener
(AFPChain afpChain) MySaveFileListener
(AFPChain afpChain, MultipleAlignment msa) Constructor to avoid checking which of the two is null before instantiating this class. -
Method Summary
Modifier and TypeMethodDescriptionvoid
void
setTextOutput
(boolean text) If true, the alignment format saved will be a text output (FASTA for MultipleAlignments and FatCat for pairwise alignments)
-
Constructor Details
-
MySaveFileListener
-
MySaveFileListener
-
MySaveFileListener
Constructor to avoid checking which of the two is null before instantiating this class. One of the two, or both, have to be null. If both are different than null the MultipleAlignment will be saved only.- Parameters:
afpChain
-msa
-
-
-
Method Details
-
actionPerformed
- Specified by:
actionPerformed
in interfaceActionListener
-
setTextOutput
public void setTextOutput(boolean text) If true, the alignment format saved will be a text output (FASTA for MultipleAlignments and FatCat for pairwise alignments)- Parameters:
text
- if true the output will be text format
-