| Index: mojo/common/common_custom_types_struct_traits.h
|
| diff --git a/mojo/common/common_custom_types_struct_traits.h b/mojo/common/common_custom_types_struct_traits.h
|
| new file mode 100644
|
| index 0000000000000000000000000000000000000000..f3190f9ac7a1624825debd1b18e6085432c0d6a7
|
| --- /dev/null
|
| +++ b/mojo/common/common_custom_types_struct_traits.h
|
| @@ -0,0 +1,25 @@
|
| +// Copyright 2016 The Chromium Authors. All rights reserved.
|
| +// Use of this source code is governed by a BSD-style license that can be
|
| +// found in the LICENSE file.
|
| +
|
| +#ifndef MOJO_COMMON_COMMON_CUSTOM_TYPES_STRUCT_TRAITS_H_
|
| +#define MOJO_COMMON_COMMON_CUSTOM_TYPES_STRUCT_TRAITS_H_
|
| +
|
| +#include "mojo/common/common_custom_types.mojom.h"
|
| +
|
| +namespace base {
|
| +class Version;
|
| +}
|
| +
|
| +namespace mojo {
|
| +
|
| +template <>
|
| +struct StructTraits<mojo::common::mojom::Version, base::Version> {
|
| + static const std::vector<uint32_t>& components(const base::Version& version);
|
| + static bool Read(mojo::common::mojom::VersionDataView data,
|
| + base::Version* out);
|
| +};
|
| +
|
| +} // namespace mojo
|
| +
|
| +#endif // MOJO_COMMON_COMMON_CUSTOM_TYPES_STRUCT_TRAITS_H_
|
|
|