pub struct Session {
pub status: SharedStatus,
pub selection: Selection,
/* private fields */
}Expand description
One owner per camera. All public entry points are serialized by the frontend. Status and queued controls remain readable while capture owns the worker.
Fields§
§status: SharedStatus§selection: SelectionImplementations§
Source§impl Session
impl Session
pub fn new( selection: Selection, runtime: Runtime, log: Diagnostic, ) -> Result<Self>
pub fn snapshot(&self) -> Status
pub async fn simulate_read_failures( &mut self, count: u32, token: &CancellationToken, ) -> Result<()>
pub fn seed_recovery(&mut self, temperature: Option<f64>, power: Option<i64>)
pub fn queue_control(status: &SharedStatus, kind: i32, value: i64) -> Result<()>
pub async fn connect(&mut self, token: &CancellationToken) -> Result<()>
pub async fn refresh(&mut self, token: &CancellationToken) -> Result<()>
pub fn ready_timeout(&self, seconds: f64) -> f64
pub async fn capture( &mut self, e: Exposure, token: &CancellationToken, ) -> Result<Frame>
pub async fn close(&mut self)
Auto Trait Implementations§
impl !RefUnwindSafe for Session
impl !UnwindSafe for Session
impl Freeze for Session
impl Send for Session
impl Sync for Session
impl Unpin for Session
impl UnsafeUnpin for Session
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