FileWriter.hpp 688 B

1234567891011121314151617181920212223242526272829303132333435
  1. /*
  2. * Author: Patrick-Christopher Mattulat
  3. * Company: Lynar Studios
  4. * E-Mail: webmaster@lynarstudios.com
  5. * Created: 2020-08-17
  6. * Changed: 2020-11-06
  7. *
  8. * */
  9. #ifndef LS_STD_FILE_WRITER_HPP
  10. #define LS_STD_FILE_WRITER_HPP
  11. #include "../../../include/ls_std/base/Class.hpp"
  12. #include "IWriter.hpp"
  13. #include "File.hpp"
  14. namespace ls_std {
  15. class FileWriter : public Class, IWriter {
  16. public:
  17. explicit FileWriter(File& _file);
  18. ~FileWriter() = default;
  19. void reset(File& _file);
  20. bool write(const ls_std::byte_field& _data) override;
  21. private:
  22. File file;
  23. static void _init(File& _file);
  24. };
  25. }
  26. #endif