[][src]Struct spectrusty::bus::zxinterface1::ZxMicrodrives

pub struct ZxMicrodrives<T> { /* fields omitted */ }

Implementation of this type emulates ZX Microdrives.

Used by ZX Interface 1 emulator.

Implementations

impl<T> ZxMicrodrives<T>[src]

pub fn replace_cartridge(
    &mut self,
    drive_index: usize,
    cartridge: MicroCartridge
) -> Option<MicroCartridge>
[src]

Inserts a cartridge into the drive_index optionally returning a cartridge that was previously in the same drive.

drive_index is a drive index number from 0 to 7.

Panics

Panics if the drive_index is above 7.

pub fn take_cartridge(&mut self, index: usize) -> Option<MicroCartridge>[src]

Removes and optionally returns a cartridge from the drive_index.

drive_index is a drive index number from 0 to 7.

Panics

Panics if the drive_index is above 7.

pub fn is_cartridge_inserted(&mut self, index: usize) -> bool[src]

Returns true if a cartridge is present in the drive_index.

drive_index is a drive index number from 0 to 7.

Panics

Panics if the drive_index is above 7.

pub fn cartridge_at(&self, index: usize) -> Option<&MicroCartridge>[src]

Returns a reference to a cartridge if it's present in the drive_index.

drive_index is a drive index number from 0 to 7.

Panics

Panics if the drive_index is above 7.

pub fn cartridge_in_use(&self) -> Option<(usize, &MicroCartridge)>[src]

Returns a reference to the cartridge that is being currently in use along with its drive index.

Trait Implementations

impl<T> Clone for ZxMicrodrives<T> where
    T: Clone
[src]

impl<T> Debug for ZxMicrodrives<T> where
    T: Debug
[src]

impl<T> Default for ZxMicrodrives<T> where
    T: Default
[src]

impl<'de, T> Deserialize<'de> for ZxMicrodrives<T> where
    T: Deserialize<'de>, 
[src]

impl<T> Serialize for ZxMicrodrives<T> where
    T: Serialize
[src]

Auto Trait Implementations

impl<T> RefUnwindSafe for ZxMicrodrives<T> where
    T: RefUnwindSafe
[src]

impl<T> Send for ZxMicrodrives<T> where
    T: Send
[src]

impl<T> Sync for ZxMicrodrives<T> where
    T: Sync
[src]

impl<T> Unpin for ZxMicrodrives<T> where
    T: Unpin
[src]

impl<T> UnwindSafe for ZxMicrodrives<T> where
    T: UnwindSafe
[src]

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> Conv for T

impl<T> Conv for T

impl<T> DeserializeOwned for T where
    T: for<'de> Deserialize<'de>, 
[src]

impl<T> FmtForward for T

impl<T> From<T> for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<S, T> IntoSample<S> for T where
    S: FromSample<T>, 
[src]

impl<T> Pipe for T where
    T: ?Sized

impl<T> Pipe for T

impl<T> PipeAsRef for T

impl<T> PipeBorrow for T

impl<T> PipeDeref for T

impl<T> PipeRef for T

impl<T> Tap for T

impl<T> Tap for T

impl<T, U> TapAsRef<U> for T where
    U: ?Sized

impl<T, U> TapBorrow<U> for T where
    U: ?Sized

impl<T> TapDeref for T

impl<T> ToOwned for T where
    T: Clone
[src]

type Owned = T

The resulting type after obtaining ownership.

impl<T> TryConv for T

impl<T> TryConv for T

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.

impl<V, T> VZip<V> for T where
    V: MultiLane<T>,