SectionPairRowValue.hpp 1.1 KB

123456789101112131415161718192021222324252627282930313233343536373839
  1. /*
  2. * Author: Patrick-Christopher Mattulat
  3. * Company: Lynar Studios
  4. * E-Mail: webmaster@lynarstudios.com
  5. * Created: 2023-02-10
  6. * Changed: 2023-05-18
  7. *
  8. * */
  9. #ifndef LS_STD_SECTION_PAIR_ROW_VALUE_HPP
  10. #define LS_STD_SECTION_PAIR_ROW_VALUE_HPP
  11. #include <ls-std/core/interface/ISerializable.hpp>
  12. #include <ls-std/io/section-pair/SectionPairRowEnumType.hpp>
  13. #include <ls-std/os/dynamic-goal.hpp>
  14. #include <string_view>
  15. namespace ls::std::io
  16. {
  17. class LS_STD_DYNAMIC_GOAL SectionPairRowValue : public ls::std::core::interface_type::ISerializable
  18. {
  19. public:
  20. explicit SectionPairRowValue(const ls::std::io::SectionPairRowEnumType &_type);
  21. ~SectionPairRowValue() noexcept override;
  22. virtual ls::std::io::SectionPairRowEnumType getType() = 0;
  23. [[nodiscard]] ls::std::core::type::byte_field marshal() override;
  24. void reserveNewLine(::std::string_view _reservedNewLine);
  25. void unmarshal(const ls::std::core::type::byte_field &_data) override;
  26. protected:
  27. ::std::string reservedNewLine{};
  28. ls::std::io::SectionPairRowEnumType type{};
  29. };
  30. }
  31. #endif