Android-cuttlefish cvd tool
|
#include <client.h>
Classes | |
struct | OverrideFd |
Public Member Functions | |
CvdClient (android::base::LogSeverity verbosity, const std::string &server_socket_path=ServerSocketPath()) | |
Result< void > | ConnectToServer () |
Result< void > | StopCvdServer (bool clear) |
Result< void > | RestartServerMatchClient () |
Private Member Functions | |
Result< void > | SetServer (const SharedFD &server) |
Result< cvd::Response > | SendRequest (const cvd::Request &request, const OverrideFd &new_control_fds={}, std::optional< SharedFD > extra_fd={}) |
Result< void > | CheckStatus (const cvd::Status &status, const std::string &rpc) |
Private Attributes | |
std::optional< UnixMessageSocket > | server_ |
std::string | server_socket_path_ |
android::base::LogSeverity | verbosity_ |
Client to the (old) cvd servers.
Even though cvd doesn't use a server anymore, it could encounter one (after a package update, for example). This class allows talking to those servers, mainly to stop them cleanly.
cuttlefish::CvdClient::CvdClient | ( | android::base::LogSeverity | verbosity, |
const std::string & | server_socket_path = ServerSocketPath() |
||
) |
|
private |
Result< void > cuttlefish::CvdClient::ConnectToServer | ( | ) |
Result< void > cuttlefish::CvdClient::RestartServerMatchClient | ( | ) |
|
private |
Result< void > cuttlefish::CvdClient::StopCvdServer | ( | bool | clear | ) |
|
private |
|
private |
|
private |