class ClientSet
Defined at line 30 of file ../../src/graphics/display/drivers/coordinator/client-set.h
Manages all of a Display Coordinator's client connections.
Instances are not thread-safe.
Public Methods
void ClientSet (inspect::Node root_node)
Creates an empty set.
`root_node` will be populated with one sub-node per connected client.
Defined at line 28 of file ../../src/graphics/display/drivers/coordinator/client-set.cc
void ~ClientSet ()
Defined at line 30 of file ../../src/graphics/display/drivers/coordinator/client-set.cc
void DispatchOnDisplaysChanged (std::span<const display::DisplayId> added_display_ids, std::span<const display::DisplayId> removed_display_ids)
Dispatches the changes to all clients.
Defined at line 34 of file ../../src/graphics/display/drivers/coordinator/client-set.cc
void ClientSet (const ClientSet & )
Defined at line 37 of file ../../src/graphics/display/drivers/coordinator/client-set.h
void ClientSet (ClientSet && )
Defined at line 38 of file ../../src/graphics/display/drivers/coordinator/client-set.h
ClientSet & operator= (const ClientSet & )
Defined at line 39 of file ../../src/graphics/display/drivers/coordinator/client-set.h
ClientSet & operator= (ClientSet && )
Defined at line 40 of file ../../src/graphics/display/drivers/coordinator/client-set.h
void DispatchOnDisplayVsync (display::DisplayId display_id, zx::time_monotonic timestamp, display::DriverConfigStamp vsync_config_stamp, display::ClientPriority client_priority)
Dispatches the VSync to the client that submitted the configuration.
`display_id`, `vsync_config_stamp`, and `client_priority` must be valid.
Defined at line 41 of file ../../src/graphics/display/drivers/coordinator/client-set.cc
void DispatchOnCaptureComplete ()
Dispatches the event to all clients.
Defined at line 57 of file ../../src/graphics/display/drivers/coordinator/client-set.cc
void SetVirtconMode (fuchsia_hardware_display::wire::VirtconMode virtcon_mode)
May change the client that owns the displays.
Defined at line 63 of file ../../src/graphics/display/drivers/coordinator/client-set.cc
zx::result<> ConnectClient (Controller * controller, display::ClientPriority client_priority, std::span<const display::DisplayId> current_display_ids, fidl::ServerEnd<fuchsia_hardware_display::Coordinator> coordinator_server_end, fidl::ClientEnd<fuchsia_hardware_display::CoordinatorListener> coordinator_listener_client_end)
Connects a client at the given priority level.
After this method completes, the client will receive an OnDisplaysChanged
event stating that the currently connected displays are those in
`displays`.
`controller` must be non-null and must outlive the ClientSet.
`client_priority`, `coordinator_server_end`, and
`coordinator_listener_client_end` must be valid.
Defined at line 87 of file ../../src/graphics/display/drivers/coordinator/client-set.cc
void OnClientDisconnected (Client * client)
`client` must point to a proxy associated with a client in this set.
This method must be called at most once for a client.
Defined at line 163 of file ../../src/graphics/display/drivers/coordinator/client-set.cc
std::optional<display::ClientPriority> FindConfigStampSource (display::DriverConfigStamp driver_config_stamp)
Returns the priority of the client that committed the display configuration.
Returns nullopt if the committed configuration does not belong to any of the
current clients. This happens if the client that committed the configuration
has disconnected.
Defined at line 144 of file ../../src/graphics/display/drivers/coordinator/client-set.cc
void Clear ()
Removes all clients, closing their connections.
Must be called before the ClientSet is destroyed. No client must be added
between the last Clear() call and the ClientSet's destruction.
Defined at line 211 of file ../../src/graphics/display/drivers/coordinator/client-set.cc
Client * GetClientOwningDisplays ()
Returns null if no client owns the displays.
Defined at line 222 of file ../../src/graphics/display/drivers/coordinator/client-set.cc