Lines Matching refs:id

70     void addStrongRef(const void* /*id*/) { }
71 void removeStrongRef(const void* /*id*/) { }
73 void addWeakRef(const void* /*id*/) { }
74 void removeWeakRef(const void* /*id*/) { }
106 ALOGD("\t%c ID %p (ref %d):", inc, refs->id, refs->ref);
124 ALOGD("\t%c ID %p (ref %d):", inc, refs->id, refs->ref);
139 void addStrongRef(const void* id) {
141 // "addStrongRef: RefBase=%p, id=%p", mBase, id);
142 addRef(&mStrongRefs, id, mStrong);
145 void removeStrongRef(const void* id) {
147 // "removeStrongRef: RefBase=%p, id=%p", mBase, id);
149 removeRef(&mStrongRefs, id);
151 addRef(&mStrongRefs, id, -mStrong);
162 void addWeakRef(const void* id) {
163 addRef(&mWeakRefs, id, mWeak);
166 void removeWeakRef(const void* id) {
168 removeRef(&mWeakRefs, id);
170 addRef(&mWeakRefs, id, -mWeak);
217 const void* id;
224 void addRef(ref_entry** refs, const void* id, int32_t mRef)
234 ref->id = id;
243 void removeRef(ref_entry** refs, const void* id)
251 if (ref->id == id) {
261 LOG_ALWAYS_FATAL("RefBase: removing id %p on RefBase %p"
263 id, mBase, this);
266 ALOGE("RefBase: removing id %p on RefBase %p"
268 id, mBase, this);
273 ALOGD("\t%c ID %p (ref %d):", inc, ref->id, ref->ref);
289 if (ref->id == old_id) {
290 ref->id = new_id;
303 inc, refs->id, refs->ref);
328 void RefBase::incStrong(const void* id) const
331 refs->incWeak(id);
333 refs->addStrongRef(id);
337 ALOGD("incStrong of %p from %p: cnt=%d\n", this, id, c);
347 void RefBase::decStrong(const void* id) const
350 refs->removeStrongRef(id);
353 ALOGD("decStrong of %p from %p: cnt=%d\n", this, id, c);
357 refs->mBase->onLastStrongRef(id);
362 refs->decWeak(id);
365 void RefBase::forceIncStrong(const void* id) const
368 refs->incWeak(id);
370 refs->addStrongRef(id);
375 ALOGD("forceIncStrong of %p from %p: cnt=%d\n", this, id, c);
397 void RefBase::weakref_type::incWeak(const void* id)
400 impl->addWeakRef(id);
406 void RefBase::weakref_type::decWeak(const void* id)
409 impl->removeWeakRef(id);
429 impl->mBase->onLastWeakRef(id);
438 bool RefBase::weakref_type::attemptIncStrong(const void* id)
440 incWeak(id);
462 || impl->mBase->onIncStrongAttempted(FIRST_INC_STRONG, id);
469 && impl->mBase->onIncStrongAttempted(FIRST_INC_STRONG, id);
472 decWeak(id);
483 impl->mBase->onLastStrongRef(id);
487 impl->addStrongRef(id);
490 ALOGD("attemptIncStrong of %p from %p: cnt=%d\n", this, id, curCount);
501 bool RefBase::weakref_type::attemptIncWeak(const void* id)
516 impl->addWeakRef(id);
537 RefBase::weakref_type* RefBase::createWeak(const void* id) const
539 mRefs->incWeak(id);
583 void RefBase::onLastStrongRef(const void* /*id*/)
587 bool RefBase::onIncStrongAttempted(uint32_t flags, const void* id)
592 void RefBase::onLastWeakRef(const void* /*id*/)