Lines Matching refs:T

238 inline bool operator _op_ (const T* o) const {                  \
242 template<template<typename C> class comparator, typename T, typename U>
243 static inline bool _wp_compare_(T* a, U* b) { in _wp_compare_()
244 return comparator<typename std::common_type<T*, U*>::type>()(a, b); in _wp_compare_()
401 template <typename T>
413 static inline wp<T> fromExisting(T* other);
419 wp(T* other); // NOLINT(implicit)
422 wp& operator=(T* other);
427 wp(const wp<T>& other);
428 explicit wp(const sp<T>& other);
437 wp& operator = (const wp<T>& other);
438 wp& operator = (const sp<T>& other);
443 void set_object_and_refs(T* other, weakref_type* refs);
447 sp<T> promote() const;
457 inline T* unsafe_get() const { return m_ptr; } in unsafe_get()
514 T* m_ptr;
540 template <typename T>
541 wp<T> wp<T>::fromExisting(T* other) { in fromExisting()
547 wp<T> ret; in fromExisting()
554 template<typename T>
555 wp<T>::wp(T* other) in wp()
561 template <typename T>
563 wp<T>::wp(U* other) : m_ptr(other) { in wp()
567 template <typename T>
568 wp<T>& wp<T>::operator=(T* other) {
576 template <typename T>
578 wp<T>& wp<T>::operator=(U* other) {
587 template<typename T>
588 wp<T>::wp(const wp<T>& other) in wp()
594 template<typename T>
595 wp<T>::wp(const sp<T>& other) in wp()
601 template<typename T> template<typename U>
602 wp<T>::wp(const wp<U>& other) in wp()
613 template<typename T> template<typename U>
614 wp<T>::wp(const sp<U>& other) in wp()
620 template<typename T>
621 wp<T>::~wp() in ~wp()
626 template<typename T>
627 wp<T>& wp<T>::operator = (const wp<T>& other)
630 T* otherPtr(other.m_ptr);
638 template<typename T>
639 wp<T>& wp<T>::operator = (const sp<T>& other)
643 T* otherPtr(other.m_ptr);
650 template<typename T> template<typename U>
651 wp<T>& wp<T>::operator = (const wp<U>& other)
662 template<typename T> template<typename U>
663 wp<T>& wp<T>::operator = (const sp<U>& other)
674 template<typename T>
675 void wp<T>::set_object_and_refs(T* other, weakref_type* refs) in set_object_and_refs()
683 template<typename T>
684 sp<T> wp<T>::promote() const in promote()
686 sp<T> result; in promote()
693 template<typename T>
694 void wp<T>::clear() in clear()
784 template <typename T, typename = void>
787 template <typename T>
788 struct is_complete_type<T, decltype(void(sizeof(T)))> : std::true_type {};
801 template <typename T, typename... Args,
802 typename std::enable_if<libutilsinternal::is_complete_type<T>::value, bool>::value = true,
803 typename std::enable_if<std::is_base_of<android::RefBase, T>::value, bool>::value = true>
804 shared_ptr<T> make_shared(Args...) { // SEE COMMENT ABOVE.
805 static_assert(!std::is_base_of<android::RefBase, T>::value, "Must use RefBase with sp<>");
808 template <typename T, typename... Args,
809 typename std::enable_if<libutilsinternal::is_complete_type<T>::value, bool>::value = true,
810 typename std::enable_if<std::is_base_of<android::RefBase, T>::value, bool>::value = true>
811 unique_ptr<T> make_unique(Args...) { // SEE COMMENT ABOVE.
812 static_assert(!std::is_base_of<android::RefBase, T>::value, "Must use RefBase with sp<>");