diff --git a/lib/libfnd/include/fnd/SimpleFile.h b/lib/libfnd/include/fnd/SimpleFile.h index 0b50e60..24d311a 100644 --- a/lib/libfnd/include/fnd/SimpleFile.h +++ b/lib/libfnd/include/fnd/SimpleFile.h @@ -20,6 +20,7 @@ namespace fnd }; SimpleFile(); + SimpleFile(const std::string& path, OpenMode mode); ~SimpleFile(); void open(const std::string& path, OpenMode mode); diff --git a/lib/libfnd/source/SimpleFile.cpp b/lib/libfnd/source/SimpleFile.cpp index d4cf048..c232869 100644 --- a/lib/libfnd/source/SimpleFile.cpp +++ b/lib/libfnd/source/SimpleFile.cpp @@ -14,6 +14,12 @@ SimpleFile::SimpleFile() : { } +SimpleFile::SimpleFile(const std::string& path, OpenMode mode) : + SimpleFile() +{ + open(path, mode); +} + SimpleFile::~SimpleFile() { close();