Home
last modified time | relevance | path

Searched refs:same_in_v (Results 1 - 3 of 3) sorted by relevance

/foundation/distributeddatamgr/kv_store/frameworks/common/
H A Dtraits.h38 // There is one in the ...Types, that is equal to T. If not, the same_in_v will be false.
40 inline constexpr bool same_in_v = (same_index_of_v<T, Types...> < sizeof...(Types)); member
90 std::enable_if_t<same_in_v<T, Types...>, T *> get_if(std::variant<Types...> *input) in get_if()
96 std::enable_if_t<same_in_v<T, Types...>, const T *> get_if(const std::variant<Types...> *input) in get_if()
102 constexpr std::enable_if_t<!same_in_v<T, Types...> && (std::is_class_v<T> && convertible_in_v<T, Types...>),
110 constexpr std::enable_if_t<!same_in_v<T, Types...> && (std::is_class_v<T> && convertible_in_v<T, Types...>),
118 std::enable_if_t<!same_in_v<T, Types...> && (!std::is_class_v<T> || !convertible_in_v<T, Types...>), T *> get_if( in get_if()
126 std::enable_if_t<!same_in_v<T, Types...> && !convertible_in_v<T, Types...>, const T *> get_if( in get_if()
/foundation/distributeddatamgr/relational_store/frameworks/native/rdb/mock/include/
H A Dtraits.h38 // There is one in the ...Types, that is equal to T. If not, the same_in_v will be false.
40 inline constexpr bool same_in_v = (same_index_of_v<T, Types...> < sizeof...(Types)); member
90 std::enable_if_t<same_in_v<T, Types...>, T *> get_if(std::variant<Types...> *input) in get_if()
96 std::enable_if_t<same_in_v<T, Types...>, const T *> get_if(const std::variant<Types...> *input) in get_if()
103 constexpr std::enable_if_t<!same_in_v<T, Types...> && convertible_in_v<T, Types...>,
112 constexpr std::enable_if_t<!same_in_v<T, Types...> && convertible_in_v<T, Types...>,
120 std::enable_if_t<!same_in_v<T, Types...> && !convertible_in_v<T, Types...>, T *> get_if(std::variant<Types...> *input) in get_if()
127 std::enable_if_t<!same_in_v<T, Types...> && !convertible_in_v<T, Types...>, const T *> get_if( in get_if()
/foundation/distributeddatamgr/kv_store/frameworks/common/test/
H A Dtraits_test.cpp65 * @tc.name: same_in_v
71 HWTEST_F(TraitsTest, same_in_v, TestSize.Level0) in HWTEST_F()
73 auto exist = Traits::same_in_v<int32_t, int32_t, double, std::vector<uint8_t>>; in HWTEST_F()
75 exist = Traits::same_in_v<std::string, int32_t, double, std::vector<uint8_t>>; in HWTEST_F()
77 exist = Traits::same_in_v<std::string>; in HWTEST_F()

Completed in 2 milliseconds