ABACUS develop
Atomic-orbital Based Ab-initio Computation at UStc
Loading...
Searching...
No Matches
file_reader.h
Go to the documentation of this file.
1#ifndef FILE_READER_H
2#define FILE_READER_H
3
4#include <fstream>
5#include <sstream>
6#include <string>
7
8namespace ModuleIO
9{
10
19{
20 public:
21 // Default constructor
22 FileReader(std::string filename);
24
25 // Check if file is open
26 bool isOpen() const;
27
28 // read a line to string stream
29 void readLine();
30
31 // read unitcell
32 void read_ucell();
33
34 std::stringstream ss;
35
36 private:
37 std::ifstream ifs;
38};
39
40} // namespace ModuleIO
41
42#endif
A base class of file reader.
Definition file_reader.h:19
void readLine()
Definition file_reader.cpp:34
std::stringstream ss
Definition file_reader.h:34
bool isOpen() const
Definition file_reader.cpp:28
void read_ucell()
Definition file_reader.cpp:50
~FileReader()
Definition file_reader.cpp:19
std::ifstream ifs
Definition file_reader.h:37
Definition input_help.cpp:10