pub struct Transport { /* private fields */ }
Expand description
A structure for querying and manipulating the JACK transport.
Implementations
sourceimpl Transport
impl Transport
sourcepub fn start(&self) -> Result<(), Error>
pub fn start(&self) -> Result<(), Error>
Start the JACK transport rolling.
Remarks
- Any client can make this request at any time.
- It takes effect no sooner than the next process cycle, perhaps later if there are slow-sync clients.
- This function is realtime-safe.
sourcepub fn stop(&self) -> Result<(), Error>
pub fn stop(&self) -> Result<(), Error>
Stop the JACK transport.
Remarks
- Any client can make this request at any time.
- It takes effect on the next process cycle.
- This function is realtime-safe.
sourcepub fn reposition(&self, pos: &TransportPosition) -> Result<(), Error>
pub fn reposition(&self, pos: &TransportPosition) -> Result<(), Error>
Request a new transport position.
Arguments
pos
- requested new transport position.
Remarks
- May be called at any time by any client.
- The new position takes effect in two process cycles.
- If there are slow-sync clients and the transport is already rolling, it will enter the
TransportState::Starting
state and begin invoking their sync_callbacks until ready. - This function is realtime-safe.
sourcepub fn locate(&self, frame: Frames) -> Result<(), Error>
pub fn locate(&self, frame: Frames) -> Result<(), Error>
Reposition the transport to a new frame number.
Arguments
frame
- frame number of new transport position.
Remarks
- May be called at any time by any client.
- The new position takes effect in two process cycles.
- If there are slow-sync clients and the transport is already rolling, it will enter the JackTransportStarting state and begin invoking their sync_callbacks until ready.
- This function is realtime-safe.
sourcepub fn query(&self) -> Result<TransportStatePosition, Error>
pub fn query(&self) -> Result<TransportStatePosition, Error>
Query the current transport state and position.
Remarks
- This function is realtime-safe, and can be called from any thread.
- If called from the process thread,
pos
corresponds to the first frame of the current cycle and the state returned is valid for the entire cycle.
sourcepub fn query_state(&self) -> Result<TransportState, Error>
pub fn query_state(&self) -> Result<TransportState, Error>
Query the current transport state.
Remarks
- This function is realtime-safe, and can be called from any thread.
- If called from the process thread, the state returned is valid for the entire cycle.
Trait Implementations
Auto Trait Implementations
Blanket Implementations
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
const: unstable · sourcepub fn borrow_mut(&mut self) -> &mut T
pub fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more