Lines Matching refs:binder
45 binder_status_t IFoo_Class_onTransact(AIBinder* binder, transaction_code_t code, const AParcel* in, in IFoo_Class_onTransact() argument
49 sp<IFoo> foo = static_cast<IFoo_Class_Data*>(AIBinder_getUserData(binder))->foo; in IFoo_Class_onTransact()
77 explicit BpFoo(AIBinder* binder) : mBinder(binder) {} in BpFoo() argument
122 AIBinder* binder = nullptr; in addService() local
126 binder = AIBinder_Weak_promote(mWeakBinder); in addService()
128 if (binder == nullptr) { in addService()
130 binder = AIBinder_new(IFoo::kClass, static_cast<void*>(new IFoo_Class_Data{this})); in addService()
134 mWeakBinder = AIBinder_Weak_new(binder); in addService()
137 binder_status_t status = AServiceManager_addService(binder, instance); in addService()
139 AIBinder_decStrong(binder); in addService()
144 AIBinder* binder = AServiceManager_getService(instance); // maybe nullptr in getService() local
145 if (binder == nullptr) { in getService()
149 if (!AIBinder_associateClass(binder, IFoo::kClass)) { in getService()
150 AIBinder_decStrong(binder); in getService()
155 AIBinder_incStrong(binder); in getService()
156 *outBinder = binder; in getService()
159 if (AIBinder_isRemote(binder)) { in getService()
160 sp<IFoo> ret = new BpFoo(binder); // takes ownership of binder in getService()
164 IFoo_Class_Data* data = static_cast<IFoo_Class_Data*>(AIBinder_getUserData(binder)); in getService()
171 CHECK(held == binder); in getService()
174 AIBinder_decStrong(binder); in getService()