| Index: mojo/public/cpp/bindings/string_traits.h
|
| diff --git a/mojo/public/cpp/bindings/string_traits.h b/mojo/public/cpp/bindings/string_traits.h
|
| index a6ade6fdf68df0c036af4edc3dd4a9289267b1d9..7d3075a579704dfb46ea68e2ca6158f54edff19f 100644
|
| --- a/mojo/public/cpp/bindings/string_traits.h
|
| +++ b/mojo/public/cpp/bindings/string_traits.h
|
| @@ -5,26 +5,10 @@
|
| #ifndef MOJO_PUBLIC_CPP_BINDINGS_STRING_TRAITS_H_
|
| #define MOJO_PUBLIC_CPP_BINDINGS_STRING_TRAITS_H_
|
|
|
| -#include "base/logging.h"
|
| -#include "mojo/public/cpp/bindings/lib/array_internal.h"
|
| +#include "mojo/public/cpp/bindings/string_data_view.h"
|
|
|
| namespace mojo {
|
|
|
| -// Access to the contents of a serialized string.
|
| -class StringDataView {
|
| - public:
|
| - explicit StringDataView(internal::String_Data* data) : data_(data) {
|
| - DCHECK(data_);
|
| - }
|
| -
|
| - const char* storage() const { return data_->storage(); }
|
| -
|
| - size_t size() const { return data_->size(); }
|
| -
|
| - private:
|
| - internal::String_Data* data_;
|
| -};
|
| -
|
| // This must be specialized for any type |T| to be serialized/deserialized as
|
| // a mojom string.
|
| //
|
| @@ -40,6 +24,7 @@ class StringDataView {
|
| // static size_t GetSize(const CustomString& input);
|
| // static const char* GetData(const CustomString& input);
|
| //
|
| +// // The caller guarantees that |!input.is_null()|.
|
| // static bool Read(StringDataView input, CustomString* output);
|
| // };
|
| //
|
|
|