Introduce CallMethodWithErrorResponse().

Taking two callbacks API (CallMethodWithErrorCallback()) is
not familiar with OnceCallback unfortunately.
So, instead, this CL introduces a ResponseOrErrorCallback,
which takes either Response* or ErrorResponse*, and it is
called on completion of CallMethod task regardless of whether it
is success or fail.

CallMethodWithErrorCallback() is deprecated now,
and the callers will be migarted into CallMethodWithErrorResponse()
in following CLs.

BUG=739622
TEST=Build.

Change-Id: Ib12e27de0d1dc09f2878679c53e0ad741c916fe9
Reviewed-on: https://chromium-review.googlesource.com/704794
Reviewed-by: Ryo Hashimoto <hashimoto@chromium.org>
Reviewed-by: Dan Erat <derat@chromium.org>
Commit-Queue: Hidehiko Abe <hidehiko@chromium.org>
Cr-Commit-Position: refs/heads/master@{#510166}

CrOS-Libchrome-Original-Commit: fe6246c6b575f97319e06b564a6d8e76cbc1ad2e
4 files changed
tree: 1a77d0df5ebd514b0b348f806f5bba23de17004e
  1. base/
  2. build/
  3. components/
  4. dbus/
  5. device/
  6. ipc/
  7. mojo/
  8. testing/
  9. third_party/
  10. ui/