template <>

class WireServer

Defined at line 4712 of file fidling/gen/sdk/fidl/fuchsia.virtualization/fuchsia.virtualization/cpp/fidl/fuchsia.virtualization/cpp/wire_messaging.h

Pure-virtual interface to be implemented by a server.

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

<

::fuchsia_virtualization::GuestLifecycle>|

and |::fidl::ServerEnd

<

::fuchsia_virtualization::GuestLifecycle>|).

Public Methods

void Create (::fuchsia_virtualization::wire::GuestLifecycleCreateRequest * request, CreateCompleter::Sync & completer)

Create a VMM configured with the provided config. This instantiates all devices and loads

the kernel without starting the VCPU or device dispatch loops.

Possible errors:

- ALREADY_RUNNING: A VMM instance is already running, and must be stopped before being

recreated.

All other errors are related to VMM initialization.

void Bind (::fuchsia_virtualization::wire::GuestLifecycleBindRequest * request, BindCompleter::Sync & completer)

Binds to the Guest protocol for an initialized guest.

This operation must be called between `Create` and `Stop`, otherwise the provided channel

will be immediately closed.

void Run (RunCompleter::Sync & completer)

Start the primary VCPU and any dispatch loop. This will not return until the VMM stops

running. On a clean shutdown (either guest or client initiated) this will return success.

Possible errors:

- ALREADY_RUNING: The VMM has already been started.

- NOT_CREATED: Run was called before the VMM was created.

- CONTROLLER_FORCED_HALT: Stop was called on a running VMM.

- VCPU_START_FAILURE: Failed to start the primary VCPU.

- VCPU_RUNTIME_FAILURE: A VCPU encountered a fatal error while running the guest.

void Stop (StopCompleter::Sync & completer)

Stop a running VMM. Returns once the dispatch loops have stopped. After Stop returns,

Create and then Run can be called again.

void WireServer ()

Defined at line 4715 of file fidling/gen/sdk/fidl/fuchsia.virtualization/fuchsia.virtualization/cpp/fidl/fuchsia.virtualization/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 4716 of file fidling/gen/sdk/fidl/fuchsia.virtualization/fuchsia.virtualization/cpp/fidl/fuchsia.virtualization/cpp/wire_messaging.h