NuriKit v0.1.0b2
Loading...
Searching...
No Matches
nuri::Mol2Reader Class Referencefinal

#include <nuri/fmt/mol2.h>

Inheritance diagram for nuri::Mol2Reader:
Collaboration diagram for nuri::Mol2Reader:

Public Member Functions

bool getnext (std::vector< std::string > &block) override
 Advance the reader to the next molecule.
bool bond_valid () const override
 Test whether the reader implementation can provide valid bond information.
Public Member Functions inherited from nuri::DefaultReaderImpl< read_mol2 >
 DefaultReaderImpl ()=default
Molecule parse (const std::vector< std::string > &block) const final
 Parse the current block and return the molecule.
Public Member Functions inherited from nuri::MoleculeReader
 MoleculeReader ()=default
 MoleculeReader (const MoleculeReader &)=delete
MoleculeReaderoperator= (const MoleculeReader &)=delete
 MoleculeReader (MoleculeReader &&) noexcept=default
MoleculeReaderoperator= (MoleculeReader &&) noexcept=default
virtual ~MoleculeReader () noexcept=default
std::vector< std::string > next ()
 Advance the reader to the next molecule.
MoleculeStream< MoleculeReaderstream ()
 Convert the reader to a stream object.

Additional Inherited Members

Protected Attributes inherited from nuri::DefaultReaderImpl< read_mol2 >
std::istream * is_

Member Function Documentation

◆ bond_valid()

bool nuri::Mol2Reader::bond_valid ( ) const
inlineoverridevirtual

Test whether the reader implementation can provide valid bond information.

Implements nuri::MoleculeReader.

◆ getnext()

bool nuri::Mol2Reader::getnext ( std::vector< std::string > & block)
overridevirtual

Advance the reader to the next molecule.

Parameters
blockThe block containing the next molecule. If true is returned, pre-existing contents of the block are discarded. Otherwise, the block is in a valid but unspecified state.
Returns
true if the reader has successfully advanced to the next molecule, false otherwise.
Note
The name of this method is loosely based on the std::getline() function due to its similar semantics. The name also prevents name collision with the (non-virtual) next() method when subclasses override this method.

Implements nuri::MoleculeReader.


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