[Android]如何支持sp 指針

\frameworks\native\libs\binder\ProcessState.cpp數據結構

class ProcessState : public virtual RefBase繼承

如上,方法是類實現繼承RefBase, 這樣就繼承了操做方法與相關計數數據結構。class

使用方法: sp<ProcessState> proc = new ProcessState;方法

sp is defined in
\frameworks\native\include\utils\StrongPointer.h數據

相關文章
相關標籤/搜索