bpp-phyl3  3.0.0
bpp::AbstractOPhyloTree Class Referenceabstract

Partial implementation of the OTree interface. More...

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

+ Inheritance diagram for bpp::AbstractOPhyloTree:
+ Collaboration diagram for bpp::AbstractOPhyloTree:

Public Member Functions

 AbstractOPhyloTree ()
 
virtual ~AbstractOPhyloTree ()
 
virtual void writePhyloTree (const PhyloTree &tree, std::ostream &out) const =0
 Write a tree to a stream. More...
 
virtual void writePhyloTree (const PhyloTree &tree, const std::string &path, bool overwrite) const
 Write a tree to a file. More...
 
virtual const std::string getDataType () const
 
virtual const std::string getFormatName () const=0
 
virtual const std::string getFormatDescription () const=0
 

Detailed Description

Partial implementation of the OTree interface.

Definition at line 288 of file IoTree.h.

Constructor & Destructor Documentation

◆ AbstractOPhyloTree()

bpp::AbstractOPhyloTree::AbstractOPhyloTree ( )
inline

Definition at line 292 of file IoTree.h.

◆ ~AbstractOPhyloTree()

virtual bpp::AbstractOPhyloTree::~AbstractOPhyloTree ( )
inlinevirtual

Definition at line 293 of file IoTree.h.

Member Function Documentation

◆ getDataType()

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

Implements bpp::IOFormat.

Definition at line 51 of file IoTree.h.

◆ writePhyloTree() [1/2]

virtual void bpp::AbstractOPhyloTree::writePhyloTree ( const PhyloTree tree,
const std::string &  path,
bool  overwrite 
) const
inlinevirtual

Write a tree to a file.

Parameters
treeA tree object.
pathThe file path.
overwriteTell if existing file must be overwritten. Otherwise append to the file.
Exceptions
ExceptionIf an error occurred.

Implements bpp::OPhyloTree.

Definition at line 297 of file IoTree.h.

References bpp::IOException::what(), and writePhyloTree().

◆ writePhyloTree() [2/2]

virtual void bpp::AbstractOPhyloTree::writePhyloTree ( const PhyloTree tree,
std::ostream &  out 
) const
pure virtual

Write a tree to a stream.

Parameters
treeA tree object.
outThe output stream.
Exceptions
ExceptionIf an error occurred.

Implements bpp::OPhyloTree.

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

Referenced by writePhyloTree().


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