template <>

class Server

Defined at line 283 of file fidling/gen/src/power/system-activity-governor/fake/fidl/test.sagcontrol/cpp/fidl/test.sagcontrol/cpp/natural_messaging.h

Public Methods

void Server ()

Defined at line 286 of file fidling/gen/src/power/system-activity-governor/fake/fidl/test.sagcontrol/cpp/fidl/test.sagcontrol/cpp/natural_messaging.h

void Set (SetRequest & request, SetCompleter::Sync & completer)

Sets the power elements to specific states supported by SAG.

The initial state of SAG is (2, 0). Boot complete logic is ignored in this protocol.

In SystemActivityGovernorState, omitting specifying a power element's state will preserve

its existing state.

void Get (GetCompleter::Sync & completer)

Return immediately with the current state of SAG.

void SetBootComplete (SetBootCompleteCompleter::Sync & completer)

Inform the Fake SAG to pass through the call and also change state.

void Watch (WatchCompleter::Sync & completer)

On a given connection, the first call will return immediately with SAG's

current state. Subsequent `Watch` requests will only

return if and only if a `test.sagcontrol.State.Set` call sends a request and SAG's

state has changed to the requested supported state.

For example, if the current state of SAG is (1, 0), the first

`Watch` will return (1, 0). If a `test.sagcontrol.State.Set`

call sends a request to change state to (2, 1), the next `Watch`

will return when the SAG's state has fully transitioned to (2, 1),

any intermediate transient state (in this example, (2, 0),

will not be returned.

Clients should use this to synchronize SAG states.

Handler bind_handler (async_dispatcher_t * dispatcher)

|bind_handler| returns a handler that binds incoming connections to this

server implementation.

The returned handler borrows the server instance.

The server must outlive the provided |dispatcher|. Only after

the dispatcher is shutdown will it be safe to destroy the servers.

The server should not be moved.

void ~Server ()

Defined at line 287 of file fidling/gen/src/power/system-activity-governor/fake/fidl/test.sagcontrol/cpp/fidl/test.sagcontrol/cpp/natural_messaging.h