update_engine: added CanRollback dbus method

Added a method to the update engine to check if a rollback
partition is available and can be booted from.
update_engine_client is also updated to call the function
when --can_rollback paramater is specified

BUG=chromium:343301
TEST=Ran "update_engine_client --can_rollback" and unit tests

Change-Id: If3fcb29a0067069a22812f60e9b67c6fdbbd18bd
Reviewed-on: https://chromium-review.googlesource.com/187157
Tested-by: Alex Vakulenko <avakulenko@chromium.org>
Reviewed-by: Don Garrett <dgarrett@chromium.org>
Commit-Queue: Alex Vakulenko <avakulenko@chromium.org>
diff --git a/update_attempter.h b/update_attempter.h
index 70381d9..d5c6adb 100644
--- a/update_attempter.h
+++ b/update_attempter.h
@@ -149,6 +149,10 @@
   // the partitions to roll back to (used in testing). Returns True on success.
   bool Rollback(bool powerwash, std::string* install_path);
 
+  // This is the internal entry point for checking if a valid rollback
+  // partition exists.
+  bool CanRollback() const;
+
   // Initiates a reboot if the current state is
   // UPDATED_NEED_REBOOT. Returns true on sucess, false otherwise.
   bool RebootIfNeeded();