template <typename T>
class sp
Defined at line 31 of file ../../third_party/android/platform/system/core/include/utils/StrongPointer.h
---------------------------------------------------------------------------
Public Methods
void sp<T> ()
Defined at line 33 of file ../../third_party/android/platform/system/core/include/utils/StrongPointer.h
T * release ()
Releases the ownership of the object managed by this instance of sp, if any.
The caller is now responsible for managing it. That is, the caller must ensure
decStrong() is called when the pointer is no longer used.
Defined at line 104 of file ../../third_party/android/platform/system/core/include/utils/StrongPointer.h
T & operator* ()
Accessors
Defined at line 112 of file ../../third_party/android/platform/system/core/include/utils/StrongPointer.h
T * operator-> ()
Defined at line 113 of file ../../third_party/android/platform/system/core/include/utils/StrongPointer.h
T * get ()
Defined at line 114 of file ../../third_party/android/platform/system/core/include/utils/StrongPointer.h
bool operator bool ()
Defined at line 115 of file ../../third_party/android/platform/system/core/include/utils/StrongPointer.h
template <typename U>
bool operator== (const wp<U> & o)
Punt these to the wp
<
> implementation.
Defined at line 119 of file ../../third_party/android/platform/system/core/include/utils/StrongPointer.h
template <typename U>
bool operator!= (const wp<U> & o)
Defined at line 124 of file ../../third_party/android/platform/system/core/include/utils/StrongPointer.h
template <typename... Args>
sp<T> make (Args &&... args)
TODO: Ideally we should find a way to increment the reference count before running the
constructor, so that generating an sp
<
> to this in the constructor is no longer dangerous.
Defined at line 202 of file ../../third_party/android/platform/system/core/include/utils/StrongPointer.h
sp<T> fromExisting (T * other)
if nullptr, returns nullptr
if a strong pointer is already available, this will retrieve it,
otherwise, this will abort
Defined at line 212 of file ../../third_party/android/platform/system/core/include/utils/StrongPointer.h
void sp<T> (T * other)
Defined at line 224 of file ../../third_party/android/platform/system/core/include/utils/StrongPointer.h
template <typename U>
void sp<T> (U * other)
Defined at line 232 of file ../../third_party/android/platform/system/core/include/utils/StrongPointer.h
sp<T> & operator= (T * other)
Defined at line 240 of file ../../third_party/android/platform/system/core/include/utils/StrongPointer.h
template <typename U>
sp<T> & operator= (U * other)
Defined at line 334 of file ../../third_party/android/platform/system/core/include/utils/StrongPointer.h
void sp<T> (const sp<T> & other)
Defined at line 253 of file ../../third_party/android/platform/system/core/include/utils/StrongPointer.h
void sp<T> (sp<T> && other)
Defined at line 260 of file ../../third_party/android/platform/system/core/include/utils/StrongPointer.h
template <typename U>
void sp<T> (const sp<U> & other)
Defined at line 265 of file ../../third_party/android/platform/system/core/include/utils/StrongPointer.h
template <typename U>
void sp<T> (sp<U> && other)
Defined at line 272 of file ../../third_party/android/platform/system/core/include/utils/StrongPointer.h
template <typename U>
sp<T> cast (const sp<U> & other)
Cast a strong pointer directly from one type to another. Constructors
allow changing types, but only if they are pointer-compatible. This does
a static_cast internally.
Defined at line 278 of file ../../third_party/android/platform/system/core/include/utils/StrongPointer.h
void ~sp<T> ()
Defined at line 284 of file ../../third_party/android/platform/system/core/include/utils/StrongPointer.h
sp<T> & operator= (const sp<T> & other)
Assignment
Defined at line 290 of file ../../third_party/android/platform/system/core/include/utils/StrongPointer.h
sp<T> & operator= (sp<T> && other)
Defined at line 302 of file ../../third_party/android/platform/system/core/include/utils/StrongPointer.h
template <typename U>
sp<T> & operator= (const sp<U> & other)
Defined at line 312 of file ../../third_party/android/platform/system/core/include/utils/StrongPointer.h
template <typename U>
sp<T> & operator= (sp<U> && other)
Defined at line 323 of file ../../third_party/android/platform/system/core/include/utils/StrongPointer.h
void force_set (T * other)
Special optimization for use by ProcessState (and nobody else).
Defined at line 345 of file ../../third_party/android/platform/system/core/include/utils/StrongPointer.h
void clear ()
Reset
Defined at line 351 of file ../../third_party/android/platform/system/core/include/utils/StrongPointer.h
Friends
template <typename Y>
class wp
template <typename Y>
class sp