class FakeGpio
Defined at line 63 of file ../../src/devices/gpio/testing/fake-gpio/fake-gpio.h
Public Methods
void FakeGpio ()
Defined at line 41 of file ../../src/devices/gpio/testing/fake-gpio/fake-gpio.cc
void GetInterrupt (GetInterruptRequestView request, GetInterruptCompleter::Sync & completer)
fidl::testing::WireTestBase
<fuchsia
_hardware_gpu::Gpio>
Defined at line 48 of file ../../src/devices/gpio/testing/fake-gpio/fake-gpio.cc
void ConfigureInterrupt (ConfigureInterruptRequestView request, ConfigureInterruptCompleter::Sync & completer)
Defined at line 71 of file ../../src/devices/gpio/testing/fake-gpio/fake-gpio.cc
void NotImplemented_ (const std::string & name, ::fidl::CompleterBase & completer)
Defined at line 78 of file ../../src/devices/gpio/testing/fake-gpio/fake-gpio.h
void SetBufferMode (SetBufferModeRequestView request, SetBufferModeCompleter::Sync & completer)
Defined at line 83 of file ../../src/devices/gpio/testing/fake-gpio/fake-gpio.cc
void Read (ReadCompleter::Sync & completer)
Defined at line 112 of file ../../src/devices/gpio/testing/fake-gpio/fake-gpio.cc
void ReleaseInterrupt (ReleaseInterruptCompleter::Sync & completer)
Defined at line 129 of file ../../src/devices/gpio/testing/fake-gpio/fake-gpio.cc
void handle_unknown_method (fidl::UnknownMethodMetadata<fuchsia_hardware_gpio::Gpio> metadata, fidl::UnknownMethodCompleter::Sync & completer)
Defined at line 134 of file ../../src/devices/gpio/testing/fake-gpio/fake-gpio.cc
uint64_t GetAltFunction ()
Return the function set by `SetAltFunction`. Will fail if the current
state isn't `AltFunction.`
Defined at line 140 of file ../../src/devices/gpio/testing/fake-gpio/fake-gpio.cc
uint8_t GetWriteValue ()
Return the value being written by the gpio. Will fail if the current state
isn't `Write`.
Defined at line 145 of file ../../src/devices/gpio/testing/fake-gpio/fake-gpio.cc
fuchsia_hardware_gpio::InterruptMode GetInterruptMode ()
Return the most recent mode set by `GetInterrupt` or
`ConfigureInterrupt`. Will fail if there is not a current state.
Defined at line 151 of file ../../src/devices/gpio/testing/fake-gpio/fake-gpio.cc
void SetInterrupt (zx::result<zx::interrupt> interrupt)
Set the interrupt used for GetInterrupt requests to `interrupt`.
Defined at line 155 of file ../../src/devices/gpio/testing/fake-gpio/fake-gpio.cc
void PushReadCallback (ReadCallback callback)
Add `callback` to the queue of callbacks used to handle `Read` requests.
Defined at line 159 of file ../../src/devices/gpio/testing/fake-gpio/fake-gpio.cc
void PushReadResponse (zx::result<bool> response)
Add a callback that will return `response` to the queue of callbacks used
to handle `Read` requests.
Defined at line 163 of file ../../src/devices/gpio/testing/fake-gpio/fake-gpio.cc
void SetDefaultReadResponse (std::optional<zx::result<bool>> response)
Set the default response for `Read` requests if the callback queue for
`Read` requests is empty. Set to none for no default response.
Defined at line 167 of file ../../src/devices/gpio/testing/fake-gpio/fake-gpio.cc
void SetSetBufferModeCallback (SetBufferModeCallback set_buffer_mode_callback)
Set the callback used for responding to SetBufferMode requests to `set_buffer_mode_callback`.
Defined at line 171 of file ../../src/devices/gpio/testing/fake-gpio/fake-gpio.cc
void SetCurrentState (State state)
Set the current state to `state`.
Defined at line 175 of file ../../src/devices/gpio/testing/fake-gpio/fake-gpio.cc
std::vector<State> GetStateLog ()
Return the states the gpio has been set to in chronological order.
Defined at line 177 of file ../../src/devices/gpio/testing/fake-gpio/fake-gpio.cc
fidl::ClientEnd<fuchsia_hardware_gpio::Gpio> Connect ()
Serve the gpio FIDL protocol on the current dispatcher and return a client
end that can communicate with the server.
Defined at line 179 of file ../../src/devices/gpio/testing/fake-gpio/fake-gpio.cc
fuchsia_hardware_gpio::Service::InstanceHandler CreateInstanceHandler ()
Returns a handler that binds incoming gpio service connections to this
server implementation and the dispatcher of the caller.
Defined at line 186 of file ../../src/devices/gpio/testing/fake-gpio/fake-gpio.cc