Add addtional constructor to PotentialFileReader

This commit is contained in:
Richard Berger
2021-03-10 09:16:46 -05:00
parent 6b3f0ddd3b
commit c3249625ab
2 changed files with 23 additions and 2 deletions

View File

@ -40,16 +40,19 @@ using namespace LAMMPS_NS;
* \param lmp Pointer to LAMMPS instance
* \param filename Name of file to be read
* \param potential_name Name of potential style for error messages
* \param auto_convert Bitmask of supported unit conversions */
* \param name_suffix Suffix added to potential name in error messages
* \param auto_convert Bitmask of supported unit conversions
*/
PotentialFileReader::PotentialFileReader(LAMMPS *lmp,
const std::string &filename,
const std::string &potential_name,
const std::string &name_suffix,
const int auto_convert) :
Pointers(lmp),
reader(nullptr),
filename(filename),
filetype(potential_name + " potential"),
filetype(potential_name + name_suffix),
unit_convert(auto_convert)
{
if (comm->me != 0) {
@ -66,6 +69,20 @@ PotentialFileReader::PotentialFileReader(LAMMPS *lmp,
}
}
/*
* \param lmp Pointer to LAMMPS instance
* \param filename Name of file to be read
* \param potential_name Name of potential style for error messages
* \param auto_convert Bitmask of supported unit conversions
*/
PotentialFileReader::PotentialFileReader(LAMMPS *lmp,
const std::string &filename,
const std::string &potential_name,
const int auto_convert) :
PotentialFileReader(lmp, filename, potential_name, " potential", auto_convert)
{
}
/** Closes the file */
PotentialFileReader::~PotentialFileReader() {