pub struct ControllerSynchronousProxy { /* private fields */ }
Implementations§
source§impl ControllerSynchronousProxy
impl ControllerSynchronousProxy
pub fn new(channel: Channel) -> Self
pub fn into_channel(self) -> Channel
sourcepub fn wait_for_event(&self, deadline: Time) -> Result<ControllerEvent, Error>
pub fn wait_for_event(&self, deadline: Time) -> Result<ControllerEvent, Error>
Waits until an event arrives and returns it. It is safe for other threads to make concurrent requests while waiting for an event.
sourcepub fn add_entry(
&self,
interface: u64,
neighbor: &mut IpAddress,
mac: &mut MacAddress,
___deadline: Time
) -> Result<ControllerAddEntryResult, Error>
pub fn add_entry( &self, interface: u64, neighbor: &mut IpAddress, mac: &mut MacAddress, ___deadline: Time ) -> Result<ControllerAddEntryResult, Error>
Create a static entry. If a conflict is found, overwrite the existing entry. Conflicts occur when two entries have the same interface identifier and IP address.
- request
interface
identifier for the interface used for communicating with the neighbor. - request
neighbor
IP address of the neighbor. - request
mac
MAC address of the neighbor.
- error
ZX_ERR_NOT_FOUND
ifinterface
does not exist. - error
ZX_ERR_NOT_SUPPORTED
ifinterface
does not keep a neighbor table (e.g. point-to-point links).
sourcepub fn remove_entry(
&self,
interface: u64,
neighbor: &mut IpAddress,
___deadline: Time
) -> Result<ControllerRemoveEntryResult, Error>
pub fn remove_entry( &self, interface: u64, neighbor: &mut IpAddress, ___deadline: Time ) -> Result<ControllerRemoveEntryResult, Error>
Delete a dynamic or static entry.
- request
interface
identifier for the interface associated with the entry to be deleted. - request
neighbor
IP address of the entry to be deleted.
- error
ZX_ERR_NOT_FOUND
if no entries matchinterface
andneighbor
. - error
ZX_ERR_NOT_SUPPORTED
ifinterface
does not keep a neighbor table (e.g. point-to-point links).
sourcepub fn clear_entries(
&self,
interface: u64,
ip_version: IpVersion,
___deadline: Time
) -> Result<ControllerClearEntriesResult, Error>
pub fn clear_entries( &self, interface: u64, ip_version: IpVersion, ___deadline: Time ) -> Result<ControllerClearEntriesResult, Error>
Delete all dynamic and static entries belonging to an interface.
- request
interface
identifier for the interface associated with the entries to be deleted. - request
ip_version
the IP version to clear entries from.
- error
ZX_ERR_NOT_FOUND
ifinterface
does not exist. - error
ZX_ERR_NOT_SUPPORTED
ifinterface
does not keep a neighbor table (e.g. point-to-point links).
sourcepub fn update_unreachability_config(
&self,
interface: u64,
ip_version: IpVersion,
config: UnreachabilityConfig,
___deadline: Time
) -> Result<ControllerUpdateUnreachabilityConfigResult, Error>
pub fn update_unreachability_config( &self, interface: u64, ip_version: IpVersion, config: UnreachabilityConfig, ___deadline: Time ) -> Result<ControllerUpdateUnreachabilityConfigResult, Error>
Change the configuration of the neighbor discovery algorithm for an interface.
- request
interface
the interface to be configured. - request
ip_version
the IP version to be configured. - request
config
used for updating the configuration for an interface. Only the specified fields will be changed. All other fields will remain the same as the original configuration.
- error
ZX_ERR_NOT_FOUND
ifinterface
references an interface that does not exist. - error
ZX_ERR_NOT_SUPPORTED
ifinterface
references an interface that does not keep a neighbor table (e.g. point-to-point links). - error
ZX_ERR_INVALID_ARGS
ifconfig
contains an invalid value, see [fuchsia.net.neighbor/UnreachabilityConfig
] for the list of constraints.