bpp-phyl  2.2.0
bpp::ITree Class Referenceabstract

General interface for tree readers. More...

#include <Bpp/Phyl/Io/IoTree.h>

+ Inheritance diagram for bpp::ITree:
+ Collaboration diagram for bpp::ITree:

Public Member Functions

 ITree ()
 
virtual ~ITree ()
 
virtual Treeread (const std::string &path) const =0 throw (Exception)
 Read a tree from a file. More...
 
virtual Treeread (std::istream &in) const =0 throw (Exception)
 Read a tree from a stream. More...
 
virtual const std::string getDataType () const
 

Detailed Description

General interface for tree readers.

Definition at line 74 of file IoTree.h.

Constructor & Destructor Documentation

◆ ITree()

bpp::ITree::ITree ( )
inline

Definition at line 78 of file IoTree.h.

◆ ~ITree()

virtual bpp::ITree::~ITree ( )
inlinevirtual

Definition at line 79 of file IoTree.h.

Member Function Documentation

◆ getDataType()

virtual const std::string bpp::IOTree::getDataType ( ) const
inlinevirtualinherited

Definition at line 68 of file IoTree.h.

◆ read() [1/2]

virtual Tree* bpp::ITree::read ( const std::string &  path) const
throw (Exception
)
pure virtual

Read a tree from a file.

Parameters
pathThe file path.
Returns
A new tree object.
Exceptions
ExceptionIf an error occured.

Implemented in bpp::Nhx, bpp::AbstractITree, bpp::Newick, and bpp::NexusIOTree.

Referenced by bpp::PhylogeneticsApplicationTools::getTree().

◆ read() [2/2]

virtual Tree* bpp::ITree::read ( std::istream &  in) const
throw (Exception
)
pure virtual

Read a tree from a stream.

Parameters
inThe input stream.
Returns
A new tree object.
Exceptions
ExceptionIf an error occured.

Implemented in bpp::Nhx, bpp::Newick, bpp::AbstractITree, and bpp::NexusIOTree.


The documentation for this class was generated from the following file: