diff options
author | Taku Kudo <taku@google.com> | 2018-06-18 03:31:16 +0300 |
---|---|---|
committer | Taku Kudo <taku@google.com> | 2018-06-18 03:31:16 +0300 |
commit | 75c18c6e0467b32371309862259dcf6be55ace72 (patch) | |
tree | 347445d637136dd20b23d6c184c24ba1ba1df52c /src/builder.h | |
parent | 6884e10ccd24d5192b0da010ecfdb5081b1a4dc6 (diff) |
Uses abs::string_view instead of StringPiece
Diffstat (limited to 'src/builder.h')
-rw-r--r-- | src/builder.h | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/src/builder.h b/src/builder.h index 5685fa5..219a965 100644 --- a/src/builder.h +++ b/src/builder.h @@ -21,7 +21,7 @@ #include "common.h" #include "sentencepiece_model.pb.h" #include "sentencepiece_processor.h" -#include "stringpiece.h" +#include "third_party/absl/strings/string_view.h" namespace sentencepiece { namespace normalizer { @@ -46,7 +46,7 @@ class Builder { std::string *output); // Decompiles `blob` into `chars_map`. - static util::Status DecompileCharsMap(StringPiece blob, CharsMap *chars_map); + static util::Status DecompileCharsMap(absl::string_view blob, CharsMap *chars_map); // Returns a pre-compiled binary index with `name`. static util::Status GetPrecompiledCharsMap(const std::string &name, @@ -97,10 +97,10 @@ class Builder { // Format: // src_uchar1 src_uchar2 ... <tab> trg_uchar1 trg_uchar2... // (src|trg)_ucharX must be a hex of Unicode code point. - static util::Status LoadCharsMap(StringPiece filename, CharsMap *chars_map); + static util::Status LoadCharsMap(absl::string_view filename, CharsMap *chars_map); // Saves Chars map to `filename` as TSV. - static util::Status SaveCharsMap(StringPiece filename, + static util::Status SaveCharsMap(absl::string_view filename, const CharsMap &chars_map); private: |