Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit fec67a6c authored by Steven Moreland's avatar Steven Moreland Committed by android-build-merger
Browse files

Merge "libbinder: waitForVintfService" am: e13f284c

am: d42b0eb7

Change-Id: Ied89364df05a82d254e4d7c47b15f6db81584a55
parents a69c1bb8 d42b0eb7
Loading
Loading
Loading
Loading
+7 −0
Original line number Original line Diff line number Diff line
@@ -113,6 +113,13 @@ sp<INTERFACE> waitForDeclaredService(const String16& name) {
    return interface_cast<INTERFACE>(sm->waitForService(name));
    return interface_cast<INTERFACE>(sm->waitForService(name));
}
}


template<typename INTERFACE>
sp<INTERFACE> waitForVintfService(
        const String16& instance = String16("default")) {
    return waitForDeclaredService<INTERFACE>(
        INTERFACE::descriptor + String16("/") + instance);
}

template<typename INTERFACE>
template<typename INTERFACE>
status_t getService(const String16& name, sp<INTERFACE>* outService)
status_t getService(const String16& name, sp<INTERFACE>* outService)
{
{