#include <mir_protobuf_rpc_channel.h>
|
| MirProtobufRpcChannel (std::unique_ptr< StreamTransport > transport, std::shared_ptr< SurfaceMap > const &surface_map, std::shared_ptr< AsyncBufferFactory > const &buffer_factory, std::shared_ptr< DisplayConfiguration > const &disp_config, std::shared_ptr< input::InputDevices > const &input_devices, std::shared_ptr< RpcReport > const &rpc_report, std::shared_ptr< LifecycleControl > const &lifecycle_control, std::shared_ptr< PingHandler > const &ping_handler, std::shared_ptr< EventSink > const &event_sink) |
|
| ~MirProtobufRpcChannel ()=default |
|
void | on_data_available () override |
| Called by the Transport when data is available for reading. More...
|
|
void | on_disconnected () override |
| Called by the Transport when the connection to the server has been broken. More...
|
|
Fd | watch_fd () const override |
| Get a poll()able file descriptor. More...
|
|
bool | dispatch (mir::dispatch::FdEvents events) override |
| Dispatch one pending event. More...
|
|
mir::dispatch::FdEvents | relevant_events () const override |
| The set of file-descriptor events this Dispatchable handles. More...
|
|
void | process_next_request_first () |
| Switch the RpcChannel into out-of-order mode. More...
|
|
void | call_method (std::string const &method_name, google::protobuf::MessageLite const *parameters, google::protobuf::MessageLite *response, google::protobuf::Closure *complete) override |
|
virtual | ~MirBasicRpcChannel () |
|
| Observer ()=default |
|
virtual | ~Observer ()=default |
|
| Observer (Observer const &)=delete |
|
Observer & | operator= (Observer const &)=delete |
|
| Dispatchable ()=default |
|
virtual | ~Dispatchable ()=default |
|
Dispatchable & | operator= (Dispatchable const &)=delete |
|
| Dispatchable (Dispatchable const &)=delete |
|
mir::client::rpc::MirProtobufRpcChannel::~MirProtobufRpcChannel |
( |
| ) |
|
|
default |
void mir::client::rpc::MirProtobufRpcChannel::call_method |
( |
std::string const & |
method_name, |
|
|
google::protobuf::MessageLite const * |
parameters, |
|
|
google::protobuf::MessageLite * |
response, |
|
|
google::protobuf::Closure * |
complete |
|
) |
| |
|
overridevirtual |
Dispatch one pending event.
- Parameters
-
[in] | event | The set of events current on the file-descriptor |
- Returns
- False iff no more events will be produced by this Dispatchable. Dispatch should no longer be called.
- Note
- This will dispatch at most one event. If there are multiple events specified in event (eg: readable | remote_closed) then dispatch will process only one.
-
It is harmless to call dispatch() with an event that does not contain any of the events from relevant_events(). The function will do nothing in such a case.
-
An implementation of dispatch() MUST handle FdEvent::error, if only to return false and terminate further event dispatch.
Implements mir::dispatch::Dispatchable.
void mir::client::rpc::MirProtobufRpcChannel::on_data_available |
( |
| ) |
|
|
overridevirtual |
void mir::client::rpc::MirProtobufRpcChannel::on_disconnected |
( |
| ) |
|
|
overridevirtual |
Called by the Transport when the connection to the server has been broken.
- Note
- This is not guaranteed to be triggered exactly once; it may not fire during destruction of the Transport, or it may fire multiple times.
Implements mir::client::rpc::StreamTransport::Observer.
void mir::client::rpc::MirProtobufRpcChannel::process_next_request_first |
( |
| ) |
|
Switch the RpcChannel into out-of-order mode.
The first CallMethod after this method is called will be processed out of order - no server responses will be processed until the response for the next CallMethod is processed.
After the response for the next CallMethod is processed, normal processing is resumed.
No messages are discarded, only delayed.
md::FdEvents mir::client::rpc::MirProtobufRpcChannel::relevant_events |
( |
| ) |
const |
|
overridevirtual |
mir::Fd mir::client::rpc::MirProtobufRpcChannel::watch_fd |
( |
| ) |
const |
|
overridevirtual |
The documentation for this class was generated from the following files:
Copyright © 2012-2015 Canonical Ltd.
Generated on Thu Sep 8 14:50:19 UTC 2016