[][src]Struct spacebattleship::game::uniform::AddPlayerError

pub struct AddPlayerError<P: Debug, D> { /* fields omitted */ }

Error returned when trying to add a ship that already existed.

Implementations

impl<P: Debug, D> AddPlayerError<P, D>[src]

pub fn id(&self) -> &P[src]

The id of the player that was added.

pub fn dimensions(&self) -> &D[src]

The dimensions of the board that was attempted to be added.

pub fn into_inner(self) -> (P, D)[src]

Extract the ID and Dimensions from this error.

Trait Implementations

impl<I: Debug, S> Debug for AddPlayerError<I, S>[src]

impl<P: Debug, D> Display for AddPlayerError<P, D>[src]

impl<P: Debug, D> Error for AddPlayerError<P, D>[src]

impl<P: Debug, D> From<AddPlayerError<P, D>> for (P, D)[src]

fn from(err: AddPlayerError<P, D>) -> Self[src]

Allows retrieving the inner id and shape from the error with into.

Auto Trait Implementations

impl<P, D> RefUnwindSafe for AddPlayerError<P, D> where
    D: RefUnwindSafe,
    P: RefUnwindSafe

impl<P, D> Send for AddPlayerError<P, D> where
    D: Send,
    P: Send

impl<P, D> Sync for AddPlayerError<P, D> where
    D: Sync,
    P: Sync

impl<P, D> Unpin for AddPlayerError<P, D> where
    D: Unpin,
    P: Unpin

impl<P, D> UnwindSafe for AddPlayerError<P, D> where
    D: UnwindSafe,
    P: UnwindSafe

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> From<T> for T[src]

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

impl<T> ToString for T where
    T: Display + ?Sized
[src]

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.