Commit 0d6e36c0 authored by khmel@google.com's avatar khmel@google.com Committed by Commit Bot

arc: Add instance version getter for connection holder.

Sometimes checking version code is clearner than using requestes for to
extract instance for method.

BUG=None
TEST=In context of another CL.

Change-Id: Id666ee06678affc7bd88eec8c5129d1d801af070
Reviewed-on: https://chromium-review.googlesource.com/1157283
Commit-Queue: Yury Khmel <khmel@google.com>
Reviewed-by: default avatarLuis Hector Chavez <lhchavez@chromium.org>
Cr-Commit-Position: refs/heads/master@{#579827}
parent 79e2f5ab
......@@ -366,6 +366,12 @@ class ConnectionHolder {
ConnectionHolder() = default;
// Returns instance version if instance is connected or 0 otherwise.
// This method is not intended to be used directly. Instead, prefer to use
// ARC_GET_INSTANCE_FOR_METHOD() with the expected version and check if it
// is nullptr.
uint32_t instance_version() const { return impl_.instance_version(); }
// Returns true if the Mojo interface is ready at least for its version 0
// interface. Use an Observer if you want to be notified when this is ready.
// This can only be called on the thread that this class was created on.
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment