[−][src]Struct market::ApprovedProducer
Produces goods that an Inspector
has allowed.
Methods
impl<P, I> ApprovedProducer<P, I>
[src]
pub const fn new(producer: P, inspector: I) -> Self
[src]
Creates a new ApprovedProducer
.
Trait Implementations
impl<P: Debug, I: Debug> Debug for ApprovedProducer<P, I>
[src]
impl<P, I> Producer for ApprovedProducer<P, I> where
P: Producer,
I: Inspector<Good = <P as Producer>::Good>,
[src]
P: Producer,
I: Inspector<Good = <P as Producer>::Good>,
type Good = <P as Producer>::Good
The item being produced.
type Error = <P as Producer>::Error
The error when Self
is not functional. Read more
fn produce(&self, good: Self::Good) -> Result<Option<Self::Good>, Self::Error>
[src]
fn produce_all(
&self,
goods: Vec<Self::Good>
) -> Result<Vec<Self::Good>, Self::Error>
[src]
&self,
goods: Vec<Self::Good>
) -> Result<Vec<Self::Good>, Self::Error>
fn force(&self, good: Self::Good) -> Result<(), Self::Error>
[src]
Auto Trait Implementations
impl<P, I> RefUnwindSafe for ApprovedProducer<P, I> where
I: RefUnwindSafe,
P: RefUnwindSafe,
I: RefUnwindSafe,
P: RefUnwindSafe,
impl<P, I> Send for ApprovedProducer<P, I> where
I: Send,
P: Send,
I: Send,
P: Send,
impl<P, I> Sync for ApprovedProducer<P, I> where
I: Sync,
P: Sync,
I: Sync,
P: Sync,
impl<P, I> Unpin for ApprovedProducer<P, I> where
I: Unpin,
P: Unpin,
I: Unpin,
P: Unpin,
impl<P, I> UnwindSafe for ApprovedProducer<P, I> where
I: UnwindSafe,
P: UnwindSafe,
I: UnwindSafe,
P: UnwindSafe,
Blanket Implementations
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> From<T> for T
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,