summaryrefslogtreecommitdiff
path: root/src/core/common/WhitespaceHandler.hpp
diff options
context:
space:
mode:
authorAndreas Stöckel <astoecke@techfak.uni-bielefeld.de>2015-02-14 23:50:11 +0100
committerAndreas Stöckel <astoecke@techfak.uni-bielefeld.de>2015-02-14 23:50:11 +0100
commit295783320ea3855a14123f9cea163f8f5f689e07 (patch)
treef3f536f36910cce7ef8f30846b10fcb93f32b646 /src/core/common/WhitespaceHandler.hpp
parentce5ab62b564476dfacba33507f1541166fda2bfb (diff)
Moved some of the whitespace functionality back to Utils
Diffstat (limited to 'src/core/common/WhitespaceHandler.hpp')
-rw-r--r--src/core/common/WhitespaceHandler.hpp7
1 files changed, 4 insertions, 3 deletions
diff --git a/src/core/common/WhitespaceHandler.hpp b/src/core/common/WhitespaceHandler.hpp
index 1935c24..79e0518 100644
--- a/src/core/common/WhitespaceHandler.hpp
+++ b/src/core/common/WhitespaceHandler.hpp
@@ -32,7 +32,7 @@
#include <string>
#include <vector>
-#include "WhitespaceHandler.hpp"
+#include "Utils.hpp"
namespace ousia {
@@ -76,7 +76,7 @@ public:
/**
* Returns the content of the WhitespaceHandler as string.
*/
- std::string toString()
+ std::string toString() const
{
return std::string(textBuf.data(), textBuf.size());
}
@@ -214,7 +214,8 @@ inline void appendToWhitespaceHandler(WhitespaceHandler &handler, Buffer buf,
size_t start)
{
for (auto elem : buf) {
- handler.append(elem, start++);
+ handler.append(elem, start, start + 1);
+ start++;
}
}
}