pub struct PullSource<UA: UpdateAlgorithm> { /* private fields */ }
Expand description
An implementation of |fuchsia.time.external.PullSource| that routes time updates from an |UpdateAlgorithm| to clients of the fidl protocol and routes device property updates from fidl clients to the |UpdateAlgorithm|. This implementation is based on assumption that there’s only one client.
Implementations§
Source§impl<UA: UpdateAlgorithm> PullSource<UA>
impl<UA: UpdateAlgorithm> PullSource<UA>
Sourcepub fn new(update_algorithm: UA) -> Result<Self, Error>
pub fn new(update_algorithm: UA) -> Result<Self, Error>
Create a new |PullSource| that polls |update_algorithm| for time updates and starts in the |initial_status| status.
Sourcepub async fn handle_requests_for_stream(
&self,
request_stream: PullSourceRequestStream,
) -> Result<(), Error>
pub async fn handle_requests_for_stream( &self, request_stream: PullSourceRequestStream, ) -> Result<(), Error>
Handle a single client’s requests received on the given |request_stream|.
Auto Trait Implementations§
impl<UA> Freeze for PullSource<UA>where
UA: Freeze,
impl<UA> RefUnwindSafe for PullSource<UA>where
UA: RefUnwindSafe,
impl<UA> Send for PullSource<UA>where
UA: Send,
impl<UA> Sync for PullSource<UA>where
UA: Sync,
impl<UA> Unpin for PullSource<UA>where
UA: Unpin,
impl<UA> UnwindSafe for PullSource<UA>where
UA: UnwindSafe,
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more