softparsmap
Interface DataSource

All Known Implementing Classes:
AbstractDataSource

public interface DataSource

This interface is responsible of providing the package with data regarding species trees and gene sequences.


Method Summary
 PropertyFile getPropertyFile()
          Returns the property file.
 SequenceData getSequenceData(GeneLeaf leaf)
          Returns an instance that implements the interface SequenceData for a given gene leaf.
 java.lang.String getSpeciesName(SpeciesNode speciesNode)
          Returns the name of the species for a given species node.
 SpeciesNode getSpeciesTree(GeneNode geneTree)
          Returns the root to a species tree such that all genes found in the gene tree exist in this species tree.
 void initiate()
          Called by the program ComputeFamilyGroup or ComputeFamilyGroupPair once if the method Compute.initiateDataSource() returns true, else it is not called at all.
 

Method Detail

getPropertyFile

public PropertyFile getPropertyFile()
Returns the property file.

Returns:
the property file
See Also:
PropertyFile

initiate

public void initiate()
Called by the program ComputeFamilyGroup or ComputeFamilyGroupPair once if the method Compute.initiateDataSource() returns true, else it is not called at all.


getSpeciesTree

public SpeciesNode getSpeciesTree(GeneNode geneTree)
Returns the root to a species tree such that all genes found in the gene tree exist in this species tree.

Parameters:
geneTree - the root of the gene tree
Returns:
the root to the species tree
See Also:
SpeciesNode, GeneNode

getSpeciesName

public java.lang.String getSpeciesName(SpeciesNode speciesNode)
Returns the name of the species for a given species node.

Parameters:
speciesNode - is the species node.
Returns:
the name of the species that is associated with the species node
See Also:
SpeciesNode

getSequenceData

public SequenceData getSequenceData(GeneLeaf leaf)
Returns an instance that implements the interface SequenceData for a given gene leaf.

Parameters:
leaf - the gene leaf.
Returns:
an instance of SequenceData
See Also:
SequenceData