Home
last modified time | relevance | path

Searched refs:UserType (Results 1 – 25 of 34) sorted by relevance

12

/external/libchrome/mojo/public/tools/bindings/generators/cpp_templates/
Dwrapper_class_declaration.tmpl64 template <typename UserType>
65 static {{serialization_result_type}} Serialize(UserType* input) {
70 template <typename UserType>
71 static mojo::Message SerializeAsMessage(UserType* input) {
78 // as the same UserType |input| will just be moved to |output| in
80 template <typename UserType>
81 static mojo::Message WrapAsMessage(UserType input) {
84 UserType, {{struct.name}}::DataView>>(0, 0, std::move(input)));
87 template <typename UserType>
90 UserType* output) {
[all …]
Dstruct_unserialized_message_context.tmpl2 template <typename UserType, typename DataView>
11 UserType input)
16 UserType TakeData() {
28 UserType user_data_;
31 template <typename UserType, typename DataView>
33 {{struct.name}}_UnserializedMessageContext<UserType, DataView>::kMessageTag = {};
Dstruct_data_view_declaration.tmpl23 template <typename UserType>
24 WARN_UNUSED_RESULT bool Read{{name|under_to_camel}}(UserType* output) {
39 template <typename UserType>
40 WARN_UNUSED_RESULT bool Read{{name|under_to_camel}}(UserType* output) {
52 template <typename UserType>
53 WARN_UNUSED_RESULT bool Read{{name|under_to_camel}}(UserType* output) const {
87 template <typename UserType>
88 UserType Take{{name|under_to_camel}}() {
89 UserType result;
Dunion_data_view_declaration.tmpl33 template <typename UserType>
34 WARN_UNUSED_RESULT bool Read{{name|under_to_camel}}(UserType* output) {
41 template <typename UserType>
42 WARN_UNUSED_RESULT bool Read{{name|under_to_camel}}(UserType* output) const {
66 template <typename UserType>
67 UserType Take{{name|under_to_camel}}() {
69 UserType result;
Denum_serialization_declaration.tmpl17 using UserType = typename std::remove_const<MaybeConstUserType>::type;
18 using Traits = EnumTraits<{{mojom_type}}, UserType>;
20 static void Serialize(UserType input, int32_t* output) {
24 static bool Deserialize(int32_t input, UserType* output) {
Dstruct_serialization_declaration.tmpl11 using UserType = typename std::remove_const<MaybeConstUserType>::type;
12 using Traits = StructTraits<{{data_view}}, UserType>;
29 UserType* output,
Dwrapper_union_class_declaration.tmpl74 template <typename UserType>
75 static mojo::Message SerializeAsMessage(UserType* input) {
80 template <typename UserType>
82 UserType* output) {
/external/libchrome/mojo/public/cpp/bindings/lib/
Darray_serialization.h110 using UserType = typename std::remove_const<MaybeConstUserType>::type;
114 using Traits = ArrayTraits<UserType>;
150 UserType* output,
154 ArrayIterator<Traits, UserType> iterator(*output);
178 using UserType = typename std::remove_const<MaybeConstUserType>::type;
182 using Traits = ArrayTraits<UserType>;
205 UserType* output,
209 ArrayIterator<Traits, UserType> iterator(*output);
228 using UserType = typename std::remove_const<MaybeConstUserType>::type;
229 using Traits = ArrayTraits<UserType>;
[all …]
Dserialization_util.h35 typename UserType,
37 bool CallIsNullIfExists(const UserType& input) { in CallIsNullIfExists()
43 typename UserType,
45 bool CallIsNullIfExists(const UserType& input) { in CallIsNullIfExists()
62 typename UserType,
64 bool CallSetToNullIfExists(UserType* output) { in CallSetToNullIfExists()
70 typename UserType,
73 bool CallSetToNullIfExists(UserType* output) { in CallSetToNullIfExists()
Dserialization.h63 template <typename MojomType, typename UserType>
64 mojo::Message SerializeAsMessageImpl(UserType* input) {
74 template <typename MojomType, typename DataArrayType, typename UserType>
75 DataArrayType SerializeImpl(UserType* input) {
87 template <typename MojomType, typename UserType>
91 UserType* output,
Dnative_enum_serialization.h24 using UserType = typename std::remove_const<MaybeConstUserType>::type; member
25 using Traits = IPC::ParamTraits<UserType>;
32 static void Serialize(UserType input, int32_t* output) { in Serialize()
48 static bool Deserialize(int32_t input, UserType* output) { in Deserialize()
Dstring_serialization.h22 using UserType = typename std::remove_const<MaybeConstUserType>::type;
23 using Traits = StringTraits<UserType>;
41 UserType* output,
Dmap_serialization.h23 using UserType = typename std::remove_const<MaybeConstUserType>::type;
24 using Traits = MapTraits<UserType>;
85 using UserType = typename std::remove_const<MaybeConstUserType>::type;
86 using Traits = MapTraits<UserType>;
129 UserType* output,
Dnative_struct_serialization.h57 using UserType = typename std::remove_const<MaybeConstUserType>::type; member
58 using Traits = IPC::ParamTraits<UserType>;
72 UserType* out, in Deserialize()
/external/libcxx/test/std/atomics/atomics.types.operations/atomics.types.operations.req/
Dctor.pass.cpp27 struct UserType { struct
30 UserType() noexcept {} in UserType() function
31 constexpr explicit UserType(int d) noexcept : i(d) {} in UserType() argument
33 friend bool operator==(const UserType& x, const UserType& y) { in operator ==()
62 TestFunc<UserType>()(); in main()
/external/python/pybind11/tests/
Dtest_class.py4 from pybind11_tests import UserType, ConstructorStats
9 assert "pybind11_type" in repr(type(UserType))
10 assert "UserType" in repr(UserType)
27 assert doc(UserType) == "A `py::class_` type for testing"
28 assert UserType.__name__ == "UserType"
29 assert UserType.__module__ == "pybind11_tests"
30 assert UserType.get_value.__name__ == "get_value"
31 assert UserType.get_value.__module__ == "pybind11_tests"
33 assert doc(UserType.get_value) == """
38 assert doc(UserType.value) == "Get/set value using a property"
[all …]
Dpybind11_tests.cpp76 py::class_<UserType>(m, "UserType", "A `py::class_` type for testing") in PYBIND11_MODULE()
79 .def("get_value", &UserType::value, "Get value using a method") in PYBIND11_MODULE()
80 .def("set_value", &UserType::set, "Set value using a method") in PYBIND11_MODULE()
81 .def_property("value", &UserType::value, &UserType::set, "Get/set value using a property") in PYBIND11_MODULE()
82 .def("__repr__", [](const UserType& u) { return "UserType({})"_s.format(u.value()); }); in PYBIND11_MODULE()
84 py::class_<IncType, UserType>(m, "IncType") in PYBIND11_MODULE()
Dpybind11_tests.h30 class UserType {
32 UserType() = default;
33 UserType(int i) : i(i) { } in UserType() function
43 class IncType : public UserType {
45 using UserType::UserType;
Dtest_opaque_types.py3 from pybind11_tests import ConstructorStats, UserType
27 living_before = ConstructorStats.get(UserType).alive()
29 assert m.get_void_ptr_value(UserType()) # Should also work for other C++ types
30 assert ConstructorStats.get(UserType).alive() == living_before
Dtest_methods_and_attributes.cpp94 UserType v1{1};
95 UserType v2{1};
96 static UserType sv1;
97 static UserType sv2;
99 const UserType &get1() const { return v1; } in get1()
100 const UserType &get2() const { return v2; } in get2()
101 UserType get_rvalue() const { return v2; } in get_rvalue()
105 UserType TestPropRVP::sv1(1);
106 UserType TestPropRVP::sv2(1);
314 auto static_get1 = [](py::object) -> const UserType & { return TestPropRVP::sv1; }; in TEST_SUBMODULE()
[all …]
Dtest_stl.cpp125 std::vector<std::unique_ptr<UserType>> v; in TEST_SUBMODULE()
126 v.emplace_back(new UserType{7}); in TEST_SUBMODULE()
127 v.emplace_back(new UserType{42}); in TEST_SUBMODULE()
239 m.def("return_vec_of_reference_wrapper", [](std::reference_wrapper<UserType> p4) { in TEST_SUBMODULE()
240 static UserType p1{1}, p2{2}, p3{3}; in TEST_SUBMODULE()
241 return std::vector<std::reference_wrapper<UserType>> { in TEST_SUBMODULE()
/external/google-breakpad/src/testing/test/
Dgmock-actions_test.cc194 struct UserType { struct
195 UserType() : value(0) {} in UserType() function
201 EXPECT_FALSE(BuiltInDefaultValue<UserType>::Exists()); in TEST()
216 BuiltInDefaultValue<UserType>::Get(); in TEST()
223 EXPECT_FALSE(DefaultValue<const UserType>::IsSet()); in TEST()
229 EXPECT_FALSE(DefaultValue<const UserType>::Exists()); in TEST()
232 DefaultValue<const UserType>::Set(UserType()); in TEST()
235 EXPECT_EQ(0, DefaultValue<const UserType>::Get().value); in TEST()
238 EXPECT_TRUE(DefaultValue<const UserType>::Exists()); in TEST()
241 DefaultValue<const UserType>::Clear(); in TEST()
[all …]
/external/libchrome/mojo/public/cpp/test_support/
Dtest_utils.h17 template <typename MojomType, typename UserType>
18 bool SerializeAndDeserialize(UserType* input, UserType* output) { in SerializeAndDeserialize()
/external/libcxx/test/std/experimental/simd/simd.traits/
Dis_simd_flag_type.pass.cpp25 struct UserType {}; struct
35 static_assert(!ex::is_simd_flag_type<UserType>::value, "");
47 static_assert(!ex::is_simd_flag_type_v<UserType>, "");
/external/libcxx/test/std/utilities/tuple/tuple.tuple/tuple.elem/
Dtuple.by.type.fail.cpp16 struct UserType {}; struct
19 std::tuple<long, long, char, std::string, char, UserType, char> t1; in test_bad_index()

12