template <>

class WireServer

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

Pure-virtual interface to be implemented by a server.

This interface uses typed channels (i.e. |::fidl::ClientEnd

<

::test_sagcontrol::State>|

and |::fidl::ServerEnd

<

::test_sagcontrol::State>|).

Public Methods

void Set (::test_sagcontrol::wire::SystemActivityGovernorState * 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.

void WireServer ()

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

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 ~WireServer ()

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