History log of /frameworks/base/core/java/android/os/HidlSupport.java
Revision Date Author Comments (<<< Hide modified files) (Show modified files >>>)
adcb896fd6e476f277d6f1d20e2e50b8e81c4369 25-Jan-2018 Steven Moreland <smoreland@google.com> Add remaining missing HIDL SystemApi methods.

A couple methods of Java classes which became SystemApis
but were used are still @hide.

Bug: 72480743
Test: hidl_test_java
Change-Id: I0cb82384932ab1758fa7576b2125825c48a4a6c9
/frameworks/base/core/java/android/os/HidlSupport.java
e8e63aae6f705cbe316a1d9a7780f9f534bc3948 11-Jan-2018 Steven Moreland <smoreland@google.com> Allow HIDL to be used in priv-apps.

Marking HIDL as SystemApi to allow vendor apps to talk to their own
native HIDL services. This includes implementing HIDL callback objects.

HIDL (HAL interface design language) is a language that is used to
facilitate vendor<->system communication which provides guarantees
of ABI stability. For system and vendor services alike, this can also
be used for internal communication.

Bug: 67725182
Test: boot device, hidl_test_java
Change-Id: I9d028cc43ce6f81ea619f01e18f1cd772e17cbfa
/frameworks/base/core/java/android/os/HidlSupport.java
4bfa2ebb89b909ac36094fd55080d749a996f5df 05-Jan-2018 Steven Moreland <smoreland@google.com> Generic Mutable class for HIDL code.

In general, using Mutable inside of structures
or as API arguments is a code smell. However, it
is the most syntactically clean way of fetching
something out of a lambda or inner class.

Using this, one can do:
Mutable<Result> res = new Mutable<>();
hidlObject.foo((...) -> {
res.value = ...;
});

There is an alternative:
Result a[] = new Result[1];
hidlObject.foo((...) -> {
a[0] = ...;
});

However, this alternative syntax is relatively messy.

Bug: N/A
Test: boot, use w/ wifi
Change-Id: Ibff13c653cc17bd25ddbb0534ba21ef485bff7aa
/frameworks/base/core/java/android/os/HidlSupport.java
bb0bd00b009bdd78fc5f94296702fc109bfecaf3 15-Nov-2017 Yifan Hong <elsk@google.com> android.os.HidlSupport: add getPidIfSharable() for HALs

... that returns PID of the process for debuggable builds.
This calls into the C++ equivalent of the function.

Test: lshal
Bug: 68992575

Change-Id: Ia177c709c6930510035cff33dc2389441a76351d
/frameworks/base/core/java/android/os/HidlSupport.java
73b6c27a6b89fcbaf1895542222d5b50b66c6b7a 01-Nov-2017 Yifan Hong <elsk@google.com> Allow equality checking and hash for HIDL interface proxies.

IFoo.Proxy.equals() -> HidlSupport.equals() ->
IHwInterface.asBinder().equals() -> HwRemoteBinder.equals().
IFoo.Stub.equals() -> default Object.equals()

Notice that IHwInterface.asBinder() returns mRemote(of type
HwRemoteBinder) for proxies and itself (of type HwBinder) for stubs.
If IFoo.Stub.asBinder() had not return "this", its equals()
should also be overridden.

Bug: 68727931
Test: hidl_test_java

Change-Id: I916983d7bc739747145e2ebb6830226310fd4980
/frameworks/base/core/java/android/os/HidlSupport.java
8ef5feadb8b5709e8768847a73411cefa801a18f 27-Mar-2017 Yifan Hong <elsk@google.com> Add HidlSupport.java for utility methods for HIDL.

The old .equals code uses Objects.deepEquals,
which does not handle for, e.g. ArrayList<byte[]>.
Create our own recursive HidlSupport.deepEquals
and deepHashCode method to handle these edge cases.

Bug: 36454147
Test: hidl_test_java
Change-Id: I56dc48985486b561263c260cf43aa90f30d581d0
/frameworks/base/core/java/android/os/HidlSupport.java