Browse Source

Fix SonarLint findings in SerializableSectionPairDocument class

Patrick-Christopher Mattulat 11 months ago
parent
commit
c6b4bace44

+ 2 - 2
include/ls-std/io/section-pair/serialization/SerializableSectionPairDocument.hpp

@@ -3,7 +3,7 @@
 * Company:         Lynar Studios
 * E-Mail:          webmaster@lynarstudios.com
 * Created:         2023-02-16
-* Changed:         2023-05-18
+* Changed:         2023-05-19
 *
 * */
 
@@ -35,7 +35,7 @@ namespace ls::std::io
       ls::std::io::SerializableSectionPairParameter parameter{};
 
       [[nodiscard]] ls::std::core::type::byte_field _getCurrentRow(size_t _iterations, ::std::string_view _serializedDocument) const;
-      [[nodiscard]] ls::std::core::type::byte_field _getNextSerializedSection(const ls::std::core::type::byte_field &_serializedDocument);
+      [[nodiscard]] ls::std::core::type::byte_field _getNextSerializedSection(const ls::std::core::type::byte_field &_serializedDocument) const;
       [[nodiscard]] bool _isNotNewSection(::std::string_view _currentRow) const;
       void _addSection(const ls::std::core::type::byte_field &_serializedSection) const;
   };

+ 2 - 2
source/ls-std/io/section-pair/serialization/SerializableSectionPairDocument.cpp

@@ -3,7 +3,7 @@
 * Company:         Lynar Studios
 * E-Mail:          webmaster@lynarstudios.com
 * Created:         2023-02-16
-* Changed:         2023-05-18
+* Changed:         2023-05-19
 *
 * */
 
@@ -93,7 +93,7 @@ byte_field SerializableSectionPairDocument::_getCurrentRow(size_t _iterations, s
   return currentRow;
 }
 
-byte_field SerializableSectionPairDocument::_getNextSerializedSection(const byte_field &_serializedDocument)
+byte_field SerializableSectionPairDocument::_getNextSerializedSection(const byte_field &_serializedDocument) const
 {
   byte_field serializedSection{};
   byte_field currentRow{};