pub struct AnnotationControllerSynchronousProxy { /* private fields */ }Implementations§
Source§impl AnnotationControllerSynchronousProxy
impl AnnotationControllerSynchronousProxy
pub fn new(channel: Channel) -> Self
pub fn into_channel(self) -> Channel
Sourcepub fn wait_for_event(
&self,
deadline: MonotonicInstant,
) -> Result<AnnotationControllerEvent, Error>
pub fn wait_for_event( &self, deadline: MonotonicInstant, ) -> Result<AnnotationControllerEvent, 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 update_annotations(
&self,
annotations_to_set: Vec<Annotation>,
annotations_to_delete: &[AnnotationKey],
___deadline: MonotonicInstant,
) -> Result<AnnotationControllerUpdateAnnotationsResult, Error>
pub fn update_annotations( &self, annotations_to_set: Vec<Annotation>, annotations_to_delete: &[AnnotationKey], ___deadline: MonotonicInstant, ) -> Result<AnnotationControllerUpdateAnnotationsResult, Error>
Adds, updates, and removes annotations.
The server is expected to adhere to the following conventions:
- If a key in
annotations_to_setis new, a new annotation is added - If a key in
annotations_to_setalready exists, the annotation value is updated - If a key in
annotations_to_deletedoes not exist, it is ignored
The same key cannot appear twice in a call to UpdateAnnotations(). In other words, to set two Annotations with matching keys is illegal, as is an attempt to set an Annotation and also delete it.
If the operation results in an error, the annotations remain unchanged, and will not be partially updated.
- error
UpdateAnnotationsError.INVALID_ARGSif the same key exists in bothannotations_to_setandannotations_to_delete. - error
UpdateAnnotationsError.INVALID_ARGSif a key inannotations_to_setorannotations_to_deletehas an empty namespace. - error
UpdateAnnotationsError.INVALID_ARGSif anAnnotationValue.bufferinannotations_to_setcould not be read. - error
UpdateAnnotationsError.TOO_MANY_ANNOTATIONSif the operation results in more thanMAX_ANNOTATIONS_PER_ELEMENTannotations existing.
Sourcepub fn get_annotations(
&self,
___deadline: MonotonicInstant,
) -> Result<AnnotationControllerGetAnnotationsResult, Error>
pub fn get_annotations( &self, ___deadline: MonotonicInstant, ) -> Result<AnnotationControllerGetAnnotationsResult, Error>
Returns the current Annotations for the element.
- error
GetAnnotationsErrorif the annotations could not be returned.
Sourcepub fn watch_annotations(
&self,
___deadline: MonotonicInstant,
) -> Result<AnnotationControllerWatchAnnotationsResult, Error>
pub fn watch_annotations( &self, ___deadline: MonotonicInstant, ) -> Result<AnnotationControllerWatchAnnotationsResult, Error>
Returns the full set of Annotations when one or more of them have changed, or
when this method is called by the client for the first time.
This operation does not block other requests from the client, but only one
WatchAnnotations request at a time can be made on a connection. If the
client makes a second WatchAnnotations request before waiting for the
previous request to complete, the connection will be closed.
- error
WatchAnnotationsErrorif the annotations could not be returned.
Trait Implementations§
Source§impl From<AnnotationControllerSynchronousProxy> for Handle
Available on Fuchsia only.
impl From<AnnotationControllerSynchronousProxy> for Handle
Source§fn from(value: AnnotationControllerSynchronousProxy) -> Self
fn from(value: AnnotationControllerSynchronousProxy) -> Self
Source§impl From<Channel> for AnnotationControllerSynchronousProxy
Available on Fuchsia only.
impl From<Channel> for AnnotationControllerSynchronousProxy
Source§impl FromClient for AnnotationControllerSynchronousProxy
Available on Fuchsia only.
impl FromClient for AnnotationControllerSynchronousProxy
Source§type Protocol = AnnotationControllerMarker
type Protocol = AnnotationControllerMarker
Source§fn from_client(value: ClientEnd<AnnotationControllerMarker>) -> Self
fn from_client(value: ClientEnd<AnnotationControllerMarker>) -> Self
Source§impl SynchronousProxy for AnnotationControllerSynchronousProxy
Available on Fuchsia only.
impl SynchronousProxy for AnnotationControllerSynchronousProxy
Source§type Proxy = AnnotationControllerProxy
type Proxy = AnnotationControllerProxy
Source§type Protocol = AnnotationControllerMarker
type Protocol = AnnotationControllerMarker
Proxy controls.