diff options
author | claiff <claiff@mail.ru> | 2022-10-05 15:57:43 +0300 |
---|---|---|
committer | claiff <claiff@mail.ru> | 2022-10-05 15:57:43 +0300 |
commit | 43e721305c866ad4b2c4c35d1133f169e41dd49b (patch) | |
tree | c7ae9c113d29aa3350eca04f27a933bd3b5f769c /src/file/parser/settings.cpp | |
parent | 9ed43c1057eeec6a01b8fdfd4d2ee54f9df39670 (diff) | |
download | obmc-sila-smtp-43e721305c866ad4b2c4c35d1133f169e41dd49b.tar.xz |
file reader/writer split by decorators
Diffstat (limited to 'src/file/parser/settings.cpp')
-rw-r--r-- | src/file/parser/settings.cpp | 20 |
1 files changed, 0 insertions, 20 deletions
diff --git a/src/file/parser/settings.cpp b/src/file/parser/settings.cpp deleted file mode 100644 index 590ed72..0000000 --- a/src/file/parser/settings.cpp +++ /dev/null @@ -1,20 +0,0 @@ -#include "settings.hpp" - -namespace smtp::file::parser -{ - ParseResult Settings::Parse( std::string const& line ) const - { - static constexpr char DELIMITER = '='; - static constexpr size_t ZERO_POSITION = 0; - static constexpr size_t NEXT_POSITION = 1; - - auto position = line.find(DELIMITER); - if( position == std::string::npos) - { - return {}; - } - auto first_part = line.substr( ZERO_POSITION, position ); - auto second_part = line.substr(position + NEXT_POSITION, line.length()); - return {first_part, second_part}; - } -} |