[−][src]Trait proptest::arbitrary::Arbitrary
Arbitrary determines a canonical Strategy
for the implementing type.
It provides the method arbitrary_with
which generates a Strategy
for
producing arbitrary values of the implementing type (Self
). In general,
these strategies will produce the entire set of values possible for the
type, up to some size limitation or constraints set by their parameters.
When this is not desired, strategies to produce the desired values can be
built by combining Strategy
s as described in the crate documentation.
This trait analogous to
Haskell QuickCheck's implementation of Arbitrary
.
In this interpretation of Arbitrary
, Strategy
is the equivalent of
the Gen
monad. Unlike in QuickCheck, Arbitrary
is not a core component;
types do not need to implement Arbitrary
unless one wants to use
any
or other free functions in this module.
Arbitrary
currently only works for types which represent owned data as
opposed to borrowed data. This is a fundamental restriction of proptest
which may be lifted in the future as the generic associated types (GAT)
feature of Rust is implemented and stabilized.
Associated Types
type Parameters: Default
The type of parameters that arbitrary_with
accepts for configuration
of the generated Strategy
. Parameters must implement Default
.
type Strategy: Strategy<Value = Self>
The type of Strategy
used to generate values of type Self
.
Required methods
fn arbitrary_with(args: Self::Parameters) -> Self::Strategy
Provided methods
fn arbitrary() -> Self::Strategy
Generates a Strategy
for producing arbitrary values
of type the implementing type (Self
).
Calling this for the type X
is the equivalent of using
X::arbitrary_with(Default::default())
.
This method is defined in the trait for optimization for the default if you want to do that. It is a logic error to not preserve the semantics when overriding.
Implementations on Foreign Types
impl<A: Arbitrary> Arbitrary for [A; 1]
[src]
type Parameters = A::Parameters
type Strategy = UniformArrayStrategy<A::Strategy, [A; 1]>
fn arbitrary_with(args: Self::Parameters) -> Self::Strategy
[src]
impl<A: Arbitrary> Arbitrary for [A; 2]
[src]
type Parameters = A::Parameters
type Strategy = UniformArrayStrategy<A::Strategy, [A; 2]>
fn arbitrary_with(args: Self::Parameters) -> Self::Strategy
[src]
impl<A: Arbitrary> Arbitrary for [A; 3]
[src]
type Parameters = A::Parameters
type Strategy = UniformArrayStrategy<A::Strategy, [A; 3]>
fn arbitrary_with(args: Self::Parameters) -> Self::Strategy
[src]
impl<A: Arbitrary> Arbitrary for [A; 4]
[src]
type Parameters = A::Parameters
type Strategy = UniformArrayStrategy<A::Strategy, [A; 4]>
fn arbitrary_with(args: Self::Parameters) -> Self::Strategy
[src]
impl<A: Arbitrary> Arbitrary for [A; 5]
[src]
type Parameters = A::Parameters
type Strategy = UniformArrayStrategy<A::Strategy, [A; 5]>
fn arbitrary_with(args: Self::Parameters) -> Self::Strategy
[src]
impl<A: Arbitrary> Arbitrary for [A; 6]
[src]
type Parameters = A::Parameters
type Strategy = UniformArrayStrategy<A::Strategy, [A; 6]>
fn arbitrary_with(args: Self::Parameters) -> Self::Strategy
[src]
impl<A: Arbitrary> Arbitrary for [A; 7]
[src]
type Parameters = A::Parameters
type Strategy = UniformArrayStrategy<A::Strategy, [A; 7]>
fn arbitrary_with(args: Self::Parameters) -> Self::Strategy
[src]
impl<A: Arbitrary> Arbitrary for [A; 8]
[src]
type Parameters = A::Parameters
type Strategy = UniformArrayStrategy<A::Strategy, [A; 8]>
fn arbitrary_with(args: Self::Parameters) -> Self::Strategy
[src]
impl<A: Arbitrary> Arbitrary for [A; 9]
[src]
type Parameters = A::Parameters
type Strategy = UniformArrayStrategy<A::Strategy, [A; 9]>
fn arbitrary_with(args: Self::Parameters) -> Self::Strategy
[src]
impl<A: Arbitrary> Arbitrary for [A; 10]
[src]
type Parameters = A::Parameters
type Strategy = UniformArrayStrategy<A::Strategy, [A; 10]>
fn arbitrary_with(args: Self::Parameters) -> Self::Strategy
[src]
impl<A: Arbitrary> Arbitrary for [A; 11]
[src]
type Parameters = A::Parameters
type Strategy = UniformArrayStrategy<A::Strategy, [A; 11]>
fn arbitrary_with(args: Self::Parameters) -> Self::Strategy
[src]
impl<A: Arbitrary> Arbitrary for [A; 12]
[src]
type Parameters = A::Parameters
type Strategy = UniformArrayStrategy<A::Strategy, [A; 12]>
fn arbitrary_with(args: Self::Parameters) -> Self::Strategy
[src]
impl<A: Arbitrary> Arbitrary for [A; 13]
[src]
type Parameters = A::Parameters
type Strategy = UniformArrayStrategy<A::Strategy, [A; 13]>
fn arbitrary_with(args: Self::Parameters) -> Self::Strategy
[src]
impl<A: Arbitrary> Arbitrary for [A; 14]
[src]
type Parameters = A::Parameters
type Strategy = UniformArrayStrategy<A::Strategy, [A; 14]>
fn arbitrary_with(args: Self::Parameters) -> Self::Strategy
[src]
impl<A: Arbitrary> Arbitrary for [A; 15]
[src]
type Parameters = A::Parameters
type Strategy = UniformArrayStrategy<A::Strategy, [A; 15]>
fn arbitrary_with(args: Self::Parameters) -> Self::Strategy
[src]
impl<A: Arbitrary> Arbitrary for [A; 16]
[src]
type Parameters = A::Parameters
type Strategy = UniformArrayStrategy<A::Strategy, [A; 16]>
fn arbitrary_with(args: Self::Parameters) -> Self::Strategy
[src]
impl<A: Arbitrary> Arbitrary for [A; 17]
[src]
type Parameters = A::Parameters
type Strategy = UniformArrayStrategy<A::Strategy, [A; 17]>
fn arbitrary_with(args: Self::Parameters) -> Self::Strategy
[src]
impl<A: Arbitrary> Arbitrary for [A; 18]
[src]
type Parameters = A::Parameters
type Strategy = UniformArrayStrategy<A::Strategy, [A; 18]>
fn arbitrary_with(args: Self::Parameters) -> Self::Strategy
[src]
impl<A: Arbitrary> Arbitrary for [A; 19]
[src]
type Parameters = A::Parameters
type Strategy = UniformArrayStrategy<A::Strategy, [A; 19]>
fn arbitrary_with(args: Self::Parameters) -> Self::Strategy
[src]
impl<A: Arbitrary> Arbitrary for [A; 20]
[src]
type Parameters = A::Parameters
type Strategy = UniformArrayStrategy<A::Strategy, [A; 20]>
fn arbitrary_with(args: Self::Parameters) -> Self::Strategy
[src]
impl<A: Arbitrary> Arbitrary for [A; 21]
[src]
type Parameters = A::Parameters
type Strategy = UniformArrayStrategy<A::Strategy, [A; 21]>
fn arbitrary_with(args: Self::Parameters) -> Self::Strategy
[src]
impl<A: Arbitrary> Arbitrary for [A; 22]
[src]
type Parameters = A::Parameters
type Strategy = UniformArrayStrategy<A::Strategy, [A; 22]>
fn arbitrary_with(args: Self::Parameters) -> Self::Strategy
[src]
impl<A: Arbitrary> Arbitrary for [A; 23]
[src]
type Parameters = A::Parameters
type Strategy = UniformArrayStrategy<A::Strategy, [A; 23]>
fn arbitrary_with(args: Self::Parameters) -> Self::Strategy
[src]
impl<A: Arbitrary> Arbitrary for [A; 24]
[src]
type Parameters = A::Parameters
type Strategy = UniformArrayStrategy<A::Strategy, [A; 24]>
fn arbitrary_with(args: Self::Parameters) -> Self::Strategy
[src]
impl<A: Arbitrary> Arbitrary for [A; 25]
[src]
type Parameters = A::Parameters
type Strategy = UniformArrayStrategy<A::Strategy, [A; 25]>
fn arbitrary_with(args: Self::Parameters) -> Self::Strategy
[src]
impl<A: Arbitrary> Arbitrary for [A; 26]
[src]
type Parameters = A::Parameters
type Strategy = UniformArrayStrategy<A::Strategy, [A; 26]>
fn arbitrary_with(args: Self::Parameters) -> Self::Strategy
[src]
impl<A: Arbitrary> Arbitrary for [A; 27]
[src]
type Parameters = A::Parameters
type Strategy = UniformArrayStrategy<A::Strategy, [A; 27]>
fn arbitrary_with(args: Self::Parameters) -> Self::Strategy
[src]
impl<A: Arbitrary> Arbitrary for [A; 28]
[src]
type Parameters = A::Parameters
type Strategy = UniformArrayStrategy<A::Strategy, [A; 28]>
fn arbitrary_with(args: Self::Parameters) -> Self::Strategy
[src]
impl<A: Arbitrary> Arbitrary for [A; 29]
[src]
type Parameters = A::Parameters
type Strategy = UniformArrayStrategy<A::Strategy, [A; 29]>
fn arbitrary_with(args: Self::Parameters) -> Self::Strategy
[src]
impl<A: Arbitrary> Arbitrary for [A; 30]
[src]
type Parameters = A::Parameters
type Strategy = UniformArrayStrategy<A::Strategy, [A; 30]>
fn arbitrary_with(args: Self::Parameters) -> Self::Strategy
[src]
impl<A: Arbitrary> Arbitrary for [A; 31]
[src]
type Parameters = A::Parameters
type Strategy = UniformArrayStrategy<A::Strategy, [A; 31]>
fn arbitrary_with(args: Self::Parameters) -> Self::Strategy
[src]
impl<A: Arbitrary> Arbitrary for [A; 32]
[src]
type Parameters = A::Parameters
type Strategy = UniformArrayStrategy<A::Strategy, [A; 32]>
fn arbitrary_with(args: Self::Parameters) -> Self::Strategy
[src]
impl Arbitrary for bool
[src]
type Parameters = ()
type Strategy = Any
fn arbitrary_with(_args: Self::Parameters) -> Self::Strategy
[src]
impl Arbitrary for i8
[src]
type Parameters = ()
type Strategy = Any
fn arbitrary_with(_args: Self::Parameters) -> Self::Strategy
[src]
impl Arbitrary for i16
[src]
type Parameters = ()
type Strategy = Any
fn arbitrary_with(_args: Self::Parameters) -> Self::Strategy
[src]
impl Arbitrary for i32
[src]
type Parameters = ()
type Strategy = Any
fn arbitrary_with(_args: Self::Parameters) -> Self::Strategy
[src]
impl Arbitrary for i64
[src]
type Parameters = ()
type Strategy = Any
fn arbitrary_with(_args: Self::Parameters) -> Self::Strategy
[src]
impl Arbitrary for isize
[src]
type Parameters = ()
type Strategy = Any
fn arbitrary_with(_args: Self::Parameters) -> Self::Strategy
[src]
impl Arbitrary for u8
[src]
type Parameters = ()
type Strategy = Any
fn arbitrary_with(_args: Self::Parameters) -> Self::Strategy
[src]
impl Arbitrary for u16
[src]
type Parameters = ()
type Strategy = Any
fn arbitrary_with(_args: Self::Parameters) -> Self::Strategy
[src]
impl Arbitrary for u32
[src]
type Parameters = ()
type Strategy = Any
fn arbitrary_with(_args: Self::Parameters) -> Self::Strategy
[src]
impl Arbitrary for u64
[src]
type Parameters = ()
type Strategy = Any
fn arbitrary_with(_args: Self::Parameters) -> Self::Strategy
[src]
impl Arbitrary for usize
[src]
type Parameters = ()
type Strategy = Any
fn arbitrary_with(_args: Self::Parameters) -> Self::Strategy
[src]
impl Arbitrary for i128
[src]
type Parameters = ()
type Strategy = Any
fn arbitrary_with(_args: Self::Parameters) -> Self::Strategy
[src]
impl Arbitrary for u128
[src]
type Parameters = ()
type Strategy = Any
fn arbitrary_with(_args: Self::Parameters) -> Self::Strategy
[src]
impl Arbitrary for f32
[src]
type Parameters = ()
type Strategy = Any
fn arbitrary_with(_args: Self::Parameters) -> Self::Strategy
[src]
impl Arbitrary for f64
[src]
type Parameters = ()
type Strategy = Any
fn arbitrary_with(_args: Self::Parameters) -> Self::Strategy
[src]
impl Arbitrary for char
[src]
type Parameters = ()
type Strategy = CharStrategy<'static>
fn arbitrary_with(_args: Self::Parameters) -> Self::Strategy
[src]
impl Arbitrary for ()
[src]
type Parameters = ()
type Strategy = Just<Self>
fn arbitrary_with(_args: Self::Parameters) -> Self::Strategy
[src]
impl<T0: Arbitrary> Arbitrary for (T0,)
[src]
type Parameters = (T0::Parameters,)
type Strategy = (T0::Strategy,)
fn arbitrary_with(args: Self::Parameters) -> Self::Strategy
[src]
impl<T0: Arbitrary, T1: Arbitrary> Arbitrary for (T0, T1)
[src]
type Parameters = (T0::Parameters, T1::Parameters)
type Strategy = (T0::Strategy, T1::Strategy)
fn arbitrary_with(args: Self::Parameters) -> Self::Strategy
[src]
impl<T0: Arbitrary, T1: Arbitrary, T2: Arbitrary> Arbitrary for (T0, T1, T2)
[src]
type Parameters = (T0::Parameters, T1::Parameters, T2::Parameters)
type Strategy = (T0::Strategy, T1::Strategy, T2::Strategy)
fn arbitrary_with(args: Self::Parameters) -> Self::Strategy
[src]
impl<T0: Arbitrary, T1: Arbitrary, T2: Arbitrary, T3: Arbitrary> Arbitrary for (T0, T1, T2, T3)
[src]
type Parameters = (T0::Parameters, T1::Parameters, T2::Parameters, T3::Parameters)
type Strategy = (T0::Strategy, T1::Strategy, T2::Strategy, T3::Strategy)
fn arbitrary_with(args: Self::Parameters) -> Self::Strategy
[src]
impl<T0: Arbitrary, T1: Arbitrary, T2: Arbitrary, T3: Arbitrary, T4: Arbitrary> Arbitrary for (T0, T1, T2, T3, T4)
[src]
type Parameters = (T0::Parameters, T1::Parameters, T2::Parameters, T3::Parameters, T4::Parameters)
type Strategy = (T0::Strategy, T1::Strategy, T2::Strategy, T3::Strategy, T4::Strategy)
fn arbitrary_with(args: Self::Parameters) -> Self::Strategy
[src]
impl<T0: Arbitrary, T1: Arbitrary, T2: Arbitrary, T3: Arbitrary, T4: Arbitrary, T5: Arbitrary> Arbitrary for (T0, T1, T2, T3, T4, T5)
[src]
type Parameters = (T0::Parameters, T1::Parameters, T2::Parameters, T3::Parameters, T4::Parameters, T5::Parameters)
type Strategy = (T0::Strategy, T1::Strategy, T2::Strategy, T3::Strategy, T4::Strategy, T5::Strategy)
fn arbitrary_with(args: Self::Parameters) -> Self::Strategy
[src]
impl<T0: Arbitrary, T1: Arbitrary, T2: Arbitrary, T3: Arbitrary, T4: Arbitrary, T5: Arbitrary, T6: Arbitrary> Arbitrary for (T0, T1, T2, T3, T4, T5, T6)
[src]
type Parameters = (T0::Parameters, T1::Parameters, T2::Parameters, T3::Parameters, T4::Parameters, T5::Parameters, T6::Parameters)
type Strategy = (T0::Strategy, T1::Strategy, T2::Strategy, T3::Strategy, T4::Strategy, T5::Strategy, T6::Strategy)
fn arbitrary_with(args: Self::Parameters) -> Self::Strategy
[src]
impl<T0: Arbitrary, T1: Arbitrary, T2: Arbitrary, T3: Arbitrary, T4: Arbitrary, T5: Arbitrary, T6: Arbitrary, T7: Arbitrary> Arbitrary for (T0, T1, T2, T3, T4, T5, T6, T7)
[src]
type Parameters = (T0::Parameters, T1::Parameters, T2::Parameters, T3::Parameters, T4::Parameters, T5::Parameters, T6::Parameters, T7::Parameters)
type Strategy = (T0::Strategy, T1::Strategy, T2::Strategy, T3::Strategy, T4::Strategy, T5::Strategy, T6::Strategy, T7::Strategy)
fn arbitrary_with(args: Self::Parameters) -> Self::Strategy
[src]
impl<T0: Arbitrary, T1: Arbitrary, T2: Arbitrary, T3: Arbitrary, T4: Arbitrary, T5: Arbitrary, T6: Arbitrary, T7: Arbitrary, T8: Arbitrary> Arbitrary for (T0, T1, T2, T3, T4, T5, T6, T7, T8)
[src]
type Parameters = (T0::Parameters, T1::Parameters, T2::Parameters, T3::Parameters, T4::Parameters, T5::Parameters, T6::Parameters, T7::Parameters, T8::Parameters)
type Strategy = (T0::Strategy, T1::Strategy, T2::Strategy, T3::Strategy, T4::Strategy, T5::Strategy, T6::Strategy, T7::Strategy, T8::Strategy)
fn arbitrary_with(args: Self::Parameters) -> Self::Strategy
[src]
impl<T0: Arbitrary, T1: Arbitrary, T2: Arbitrary, T3: Arbitrary, T4: Arbitrary, T5: Arbitrary, T6: Arbitrary, T7: Arbitrary, T8: Arbitrary, T9: Arbitrary> Arbitrary for (T0, T1, T2, T3, T4, T5, T6, T7, T8, T9)
[src]
type Parameters = (T0::Parameters, T1::Parameters, T2::Parameters, T3::Parameters, T4::Parameters, T5::Parameters, T6::Parameters, T7::Parameters, T8::Parameters, T9::Parameters)
type Strategy = (T0::Strategy, T1::Strategy, T2::Strategy, T3::Strategy, T4::Strategy, T5::Strategy, T6::Strategy, T7::Strategy, T8::Strategy, T9::Strategy)
fn arbitrary_with(args: Self::Parameters) -> Self::Strategy
[src]
impl Arbitrary for EscapeDefault
[src]
type Parameters = ()
type Strategy = SMapped<u8, Self>
fn arbitrary_with(_args: Self::Parameters) -> Self::Strategy
[src]
impl<A: Arbitrary + Copy> Arbitrary for Cell<A>
[src]
type Parameters = A::Parameters
type Strategy = MapInto<A::Strategy, Self>
fn arbitrary_with(args: Self::Parameters) -> Self::Strategy
[src]
impl<A: Arbitrary> Arbitrary for RefCell<A>
[src]
type Parameters = A::Parameters
type Strategy = MapInto<A::Strategy, Self>
fn arbitrary_with(args: Self::Parameters) -> Self::Strategy
[src]
impl<A: Arbitrary> Arbitrary for UnsafeCell<A>
[src]
type Parameters = A::Parameters
type Strategy = MapInto<A::Strategy, Self>
fn arbitrary_with(args: Self::Parameters) -> Self::Strategy
[src]
impl Arbitrary for BorrowError
[src]
type Parameters = ()
type Strategy = LazyJust<Self, fn() -> Self>
fn arbitrary_with(_args: Self::Parameters) -> Self::Strategy
[src]
impl Arbitrary for BorrowMutError
[src]
type Parameters = ()
type Strategy = LazyJust<Self, fn() -> Self>
fn arbitrary_with(_args: Self::Parameters) -> Self::Strategy
[src]
impl<A: Arbitrary> Arbitrary for Reverse<A>
[src]
type Parameters = A::Parameters
type Strategy = SMapped<A, Self>
fn arbitrary_with(args: Self::Parameters) -> Self::Strategy
[src]
impl Arbitrary for Ordering
[src]
type Parameters = ()
type Strategy = TupleUnion<(WA<Just<Ordering>>, WA<Just<Ordering>>, WA<Just<Ordering>>)>
fn arbitrary_with(_args: Self::Parameters) -> Self::Strategy
[src]
impl Arbitrary for Error
[src]
type Parameters = ()
type Strategy = Just<Self>
fn arbitrary_with(_args: Self::Parameters) -> Self::Strategy
[src]
impl<A: Arbitrary> Arbitrary for Once<A>
[src]
type Parameters = A::Parameters
type Strategy = SMapped<A, Self>
fn arbitrary_with(args: Self::Parameters) -> Self::Strategy
[src]
impl<A: Arbitrary + Clone> Arbitrary for Repeat<A>
[src]
type Parameters = A::Parameters
type Strategy = SMapped<A, Self>
fn arbitrary_with(args: Self::Parameters) -> Self::Strategy
[src]
impl<A: Arbitrary + Iterator + Clone> Arbitrary for Cycle<A>
[src]
type Parameters = A::Parameters
type Strategy = SMapped<A, Self>
fn arbitrary_with(args: Self::Parameters) -> Self::Strategy
[src]
impl<A: Arbitrary + Iterator> Arbitrary for Enumerate<A>
[src]
type Parameters = A::Parameters
type Strategy = SMapped<A, Self>
fn arbitrary_with(args: Self::Parameters) -> Self::Strategy
[src]
impl<A: Arbitrary + Iterator> Arbitrary for Fuse<A>
[src]
type Parameters = A::Parameters
type Strategy = SMapped<A, Self>
fn arbitrary_with(args: Self::Parameters) -> Self::Strategy
[src]
impl<A: Arbitrary + Iterator<Item = T>, T: Debug> Arbitrary for Peekable<A>
[src]
type Parameters = A::Parameters
type Strategy = SMapped<A, Self>
fn arbitrary_with(args: Self::Parameters) -> Self::Strategy
[src]
impl<A: Arbitrary + DoubleEndedIterator> Arbitrary for Rev<A>
[src]
type Parameters = A::Parameters
type Strategy = SMapped<A, Self>
fn arbitrary_with(args: Self::Parameters) -> Self::Strategy
[src]
impl<'a, T: 'a + Clone, A: Arbitrary + Iterator<Item = &'a T>> Arbitrary for Cloned<A>
[src]
type Parameters = A::Parameters
type Strategy = SMapped<A, Self>
fn arbitrary_with(args: Self::Parameters) -> Self::Strategy
[src]
impl<A> Arbitrary for Empty<A>
[src]
type Parameters = ()
type Strategy = Just<Self>
fn arbitrary_with(_args: Self::Parameters) -> Self::Strategy
[src]
impl<A: Arbitrary + Iterator, B: Arbitrary + Iterator> Arbitrary for Zip<A, B>
[src]
type Parameters = (A::Parameters, B::Parameters)
type Strategy = SMapped<(A, B), Self>
fn arbitrary_with(args: Self::Parameters) -> Self::Strategy
[src]
impl<T, A: Arbitrary + Iterator<Item = T>, B: Arbitrary + Iterator<Item = T>> Arbitrary for Chain<A, B>
[src]
type Parameters = (A::Parameters, B::Parameters)
type Strategy = SMapped<(A, B), Self>
fn arbitrary_with(args: Self::Parameters) -> Self::Strategy
[src]
impl<A: Arbitrary + Iterator> Arbitrary for Skip<A>
[src]
type Parameters = A::Parameters
type Strategy = SMapped<(A, usize), Self>
fn arbitrary_with(a: Self::Parameters) -> Self::Strategy
[src]
impl<A: Arbitrary + Iterator> Arbitrary for Take<A>
[src]
type Parameters = A::Parameters
type Strategy = SMapped<(A, usize), Self>
fn arbitrary_with(a: Self::Parameters) -> Self::Strategy
[src]
impl<T: ?Sized> Arbitrary for PhantomData<T>
[src]
type Parameters = ()
type Strategy = Just<Self>
fn arbitrary_with(_args: Self::Parameters) -> Self::Strategy
[src]
impl<A: Arbitrary> Arbitrary for Discriminant<A>
[src]
type Parameters = A::Parameters
type Strategy = SMapped<A, Self>
fn arbitrary_with(args: Self::Parameters) -> Self::Strategy
[src]
impl Arbitrary for ParseFloatError
[src]
type Parameters = ()
type Strategy = Just<Self>
fn arbitrary_with(_args: Self::Parameters) -> Self::Strategy
[src]
impl Arbitrary for ParseIntError
[src]
type Parameters = ()
type Strategy = Just<Self>
fn arbitrary_with(_args: Self::Parameters) -> Self::Strategy
[src]
impl<A: Arbitrary> Arbitrary for Wrapping<A>
[src]
type Parameters = A::Parameters
type Strategy = SMapped<A, Self>
fn arbitrary_with(args: Self::Parameters) -> Self::Strategy
[src]
impl Arbitrary for FpCategory
[src]
type Parameters = ()
type Strategy = TupleUnion<(WA<Just<Self>>, WA<Just<Self>>, WA<Just<Self>>, WA<Just<Self>>, WA<Just<Self>>)>
fn arbitrary_with(_args: Self::Parameters) -> Self::Strategy
[src]
impl Arbitrary for Option<ParseError>
[src]
type Parameters = ()
type Strategy = Just<Self>
fn arbitrary_with(_args: Self::Parameters) -> Self::Strategy
[src]
impl<A: Arbitrary> Arbitrary for Option<A>
[src]
type Parameters = (Probability, A::Parameters)
type Strategy = OptionStrategy<A::Strategy>
fn arbitrary_with(args: Self::Parameters) -> Self::Strategy
[src]
impl<A: Arbitrary> Arbitrary for IntoIter<A>
[src]
type Parameters = <Option<A> as Arbitrary>::Parameters
type Strategy = SMapped<Option<A>, Self>
fn arbitrary_with(args: Self::Parameters) -> Self::Strategy
[src]
impl<A: Arbitrary> Arbitrary for Result<A, ParseError>
[src]
type Parameters = A::Parameters
type Strategy = SMapped<A, Self>
fn arbitrary_with(args: Self::Parameters) -> Self::Strategy
[src]
impl<A: Arbitrary> Arbitrary for Result<ParseError, A>
[src]
type Parameters = A::Parameters
type Strategy = SMapped<A, Self>
fn arbitrary_with(args: Self::Parameters) -> Self::Strategy
[src]
impl<A: Arbitrary, B: Arbitrary> Arbitrary for Result<A, B>
[src]
type Parameters = (Probability, A::Parameters, B::Parameters)
type Strategy = MaybeOk<A::Strategy, B::Strategy>
fn arbitrary_with(args: Self::Parameters) -> Self::Strategy
[src]
impl<A: Arbitrary> Arbitrary for IntoIter<A>
[src]
type Parameters = <Result<A, ()> as Arbitrary>::Parameters
type Strategy = SMapped<Result<A, ()>, Self>
fn arbitrary_with(args: Self::Parameters) -> Self::Strategy
[src]
impl<A: Arbitrary + Borrow<B>, B: ToOwned<Owned = A> + Debug + ?Sized> Arbitrary for Cow<'static, B>
[src]
type Parameters = A::Parameters
type Strategy = SMapped<A, Self>
fn arbitrary_with(args: Self::Parameters) -> Self::Strategy
[src]
impl<A: Arbitrary> Arbitrary for Box<A>
[src]
type Parameters = A::Parameters
type Strategy = MapInto<A::Strategy, Self>
fn arbitrary_with(args: Self::Parameters) -> Self::Strategy
[src]
impl Arbitrary for EscapeDebug
[src]
type Parameters = ()
type Strategy = SMapped<char, Self>
fn arbitrary_with(_args: Self::Parameters) -> Self::Strategy
[src]
impl Arbitrary for EscapeDefault
[src]
type Parameters = ()
type Strategy = SMapped<char, Self>
fn arbitrary_with(_args: Self::Parameters) -> Self::Strategy
[src]
impl Arbitrary for EscapeUnicode
[src]
type Parameters = ()
type Strategy = SMapped<char, Self>
fn arbitrary_with(_args: Self::Parameters) -> Self::Strategy
[src]
impl Arbitrary for DecodeUtf16<<Vec<u16> as IntoIterator>::IntoIter>
[src]
type Parameters = ()
type Strategy = SMapped<Vec<u16>, Self>
fn arbitrary_with(_args: Self::Parameters) -> Self::Strategy
[src]
impl Arbitrary for ParseCharError
[src]
type Parameters = ()
type Strategy = IndFlatten<Mapped<bool, Just<Self>>>
fn arbitrary_with(_args: Self::Parameters) -> Self::Strategy
[src]
impl Arbitrary for DecodeUtf16Error
[src]
type Parameters = ()
type Strategy = Map<Range<u16>, fn(_: <Range<u16> as Strategy>::Value) -> Self>
fn arbitrary_with(_args: Self::Parameters) -> Self::Strategy
[src]
impl<A: Arbitrary> Arbitrary for Vec<A>
[src]
type Parameters = (SizeRange, A::Parameters)
type Strategy = VecStrategy<A::Strategy>
fn arbitrary_with(args: Self::Parameters) -> Self::Strategy
[src]
impl<A: Arbitrary> Arbitrary for Box<[A]>
[src]
type Parameters = <Vec<A> as Arbitrary>::Parameters
type Strategy = MapInto<StrategyFor<Vec<A>>, Self>
fn arbitrary_with(a: Self::Parameters) -> Self::Strategy
[src]
impl<A: Arbitrary> Arbitrary for Rc<[A]>
[src]
type Parameters = <Vec<A> as Arbitrary>::Parameters
type Strategy = MapInto<StrategyFor<Vec<A>>, Self>
fn arbitrary_with(a: Self::Parameters) -> Self::Strategy
[src]
impl<A: Arbitrary> Arbitrary for Arc<[A]>
[src]
type Parameters = <Vec<A> as Arbitrary>::Parameters
type Strategy = MapInto<StrategyFor<Vec<A>>, Self>
fn arbitrary_with(a: Self::Parameters) -> Self::Strategy
[src]
impl<A: Arbitrary> Arbitrary for VecDeque<A>
[src]
type Parameters = (SizeRange, A::Parameters)
type Strategy = VecDequeStrategy<A::Strategy>
fn arbitrary_with(args: Self::Parameters) -> Self::Strategy
[src]
impl<A: Arbitrary> Arbitrary for LinkedList<A>
[src]
type Parameters = (SizeRange, A::Parameters)
type Strategy = LinkedListStrategy<A::Strategy>
fn arbitrary_with(args: Self::Parameters) -> Self::Strategy
[src]
impl<A: Arbitrary + Ord> Arbitrary for BTreeSet<A>
[src]
type Parameters = (SizeRange, A::Parameters)
type Strategy = BTreeSetStrategy<A::Strategy>
fn arbitrary_with(args: Self::Parameters) -> Self::Strategy
[src]
impl<A: Arbitrary + Ord> Arbitrary for BinaryHeap<A>
[src]
type Parameters = (SizeRange, A::Parameters)
type Strategy = BinaryHeapStrategy<A::Strategy>
fn arbitrary_with(args: Self::Parameters) -> Self::Strategy
[src]
impl<A: Arbitrary + Hash + Eq> Arbitrary for HashSet<A>
[src]
type Parameters = (SizeRange, A::Parameters)
type Strategy = HashSetStrategy<A::Strategy>
fn arbitrary_with(args: Self::Parameters) -> Self::Strategy
[src]
impl<A: Arbitrary> Arbitrary for IntoIter<A>
[src]
type Parameters = <Vec<A> as Arbitrary>::Parameters
type Strategy = SMapped<Vec<A>, Self>
fn arbitrary_with(args: Self::Parameters) -> Self::Strategy
[src]
impl<A: Arbitrary> Arbitrary for IntoIter<A>
[src]
type Parameters = <VecDeque<A> as Arbitrary>::Parameters
type Strategy = SMapped<VecDeque<A>, Self>
fn arbitrary_with(args: Self::Parameters) -> Self::Strategy
[src]
impl<A: Arbitrary> Arbitrary for IntoIter<A>
[src]
type Parameters = <LinkedList<A> as Arbitrary>::Parameters
type Strategy = SMapped<LinkedList<A>, Self>
fn arbitrary_with(args: Self::Parameters) -> Self::Strategy
[src]
impl<A: Arbitrary + Ord> Arbitrary for IntoIter<A>
[src]
type Parameters = <BTreeSet<A> as Arbitrary>::Parameters
type Strategy = SMapped<BTreeSet<A>, Self>
fn arbitrary_with(args: Self::Parameters) -> Self::Strategy
[src]
impl<A: Arbitrary + Ord> Arbitrary for IntoIter<A>
[src]
type Parameters = <BinaryHeap<A> as Arbitrary>::Parameters
type Strategy = SMapped<BinaryHeap<A>, Self>
fn arbitrary_with(args: Self::Parameters) -> Self::Strategy
[src]
impl<A: Arbitrary + Hash + Eq> Arbitrary for IntoIter<A>
[src]
type Parameters = <HashSet<A> as Arbitrary>::Parameters
type Strategy = SMapped<HashSet<A>, Self>
fn arbitrary_with(args: Self::Parameters) -> Self::Strategy
[src]
impl<A: Arbitrary + Hash + Eq, B: Arbitrary> Arbitrary for HashMap<A, B>
[src]
type Parameters = (SizeRange, A::Parameters, B::Parameters)
type Strategy = HashMapStrategy<A::Strategy, B::Strategy>
fn arbitrary_with(args: Self::Parameters) -> Self::Strategy
[src]
impl<A: Arbitrary + Hash + Eq, B: Arbitrary> Arbitrary for IntoIter<A, B>
[src]
type Parameters = <HashMap<A, B> as Arbitrary>::Parameters
type Strategy = SMapped<HashMap<A, B>, Self>
fn arbitrary_with(args: Self::Parameters) -> Self::Strategy
[src]
impl<A: Arbitrary + Ord, B: Arbitrary> Arbitrary for BTreeMap<A, B>
[src]
type Parameters = (SizeRange, A::Parameters, B::Parameters)
type Strategy = BTreeMapStrategy<A::Strategy, B::Strategy>
fn arbitrary_with(args: Self::Parameters) -> Self::Strategy
[src]
impl<A: Arbitrary + Ord, B: Arbitrary> Arbitrary for IntoIter<A, B>
[src]
type Parameters = <BTreeMap<A, B> as Arbitrary>::Parameters
type Strategy = SMapped<BTreeMap<A, B>, Self>
fn arbitrary_with(args: Self::Parameters) -> Self::Strategy
[src]
impl<A: Arbitrary> Arbitrary for Bound<A>
[src]
type Parameters = A::Parameters
type Strategy = TupleUnion<(WA<Map<Arc<A::Strategy>, fn(_: <Arc<A::Strategy> as Strategy>::Value) -> Self>>, WA<Map<Arc<A::Strategy>, fn(_: <Arc<A::Strategy> as Strategy>::Value) -> Self>>, WA<LazyJustFn<Self>>)>
fn arbitrary_with(args: Self::Parameters) -> Self::Strategy
[src]
impl<H: Default + Hasher> Arbitrary for BuildHasherDefault<H>
[src]
type Parameters = ()
type Strategy = Just<Self>
fn arbitrary_with(_args: Self::Parameters) -> Self::Strategy
[src]
impl Arbitrary for DefaultHasher
[src]
type Parameters = ()
type Strategy = LazyJust<Self, fn() -> Self>
fn arbitrary_with(_args: Self::Parameters) -> Self::Strategy
[src]
impl Arbitrary for RandomState
[src]
type Parameters = ()
type Strategy = LazyJust<Self, fn() -> Self>
fn arbitrary_with(_args: Self::Parameters) -> Self::Strategy
[src]
impl Arbitrary for RangeFull
[src]
type Parameters = ()
type Strategy = Just<Self>
fn arbitrary_with(_args: Self::Parameters) -> Self::Strategy
[src]
impl<A: Arbitrary> Arbitrary for RangeFrom<A>
[src]
type Parameters = A::Parameters
type Strategy = SMapped<A, Self>
fn arbitrary_with(args: Self::Parameters) -> Self::Strategy
[src]
impl<A: Arbitrary> Arbitrary for RangeTo<A>
[src]
type Parameters = A::Parameters
type Strategy = SMapped<A, Self>
fn arbitrary_with(args: Self::Parameters) -> Self::Strategy
[src]
impl<A: Arbitrary> Arbitrary for RangeToInclusive<A>
[src]
type Parameters = A::Parameters
type Strategy = SMapped<A, Self>
fn arbitrary_with(args: Self::Parameters) -> Self::Strategy
[src]
impl<A: PartialOrd + Arbitrary> Arbitrary for RangeInclusive<A>
[src]
type Parameters = (A::Parameters, A::Parameters)
type Strategy = SMapped<(A, A), Self>
fn arbitrary_with(args: Self::Parameters) -> Self::Strategy
[src]
impl<A: PartialOrd + Arbitrary> Arbitrary for Range<A>
[src]
type Parameters = (A::Parameters, A::Parameters)
type Strategy = SMapped<(A, A), Self>
fn arbitrary_with(args: Self::Parameters) -> Self::Strategy
[src]
impl<A: Arbitrary> Arbitrary for Rc<A>
[src]
type Parameters = A::Parameters
type Strategy = MapInto<A::Strategy, Self>
fn arbitrary_with(args: Self::Parameters) -> Self::Strategy
[src]
impl Arbitrary for ParseBoolError
[src]
type Parameters = ()
type Strategy = Just<Self>
fn arbitrary_with(_args: Self::Parameters) -> Self::Strategy
[src]
impl Arbitrary for Utf8Error
[src]
type Parameters = ()
type Strategy = Map<(StrategyFor<u16>, TupleUnion<(WA<Just<&'static [u8]>>, WA<Just<&'static [u8]>>, WA<Just<&'static [u8]>>, WA<Just<&'static [u8]>>)>), fn(_: <(StrategyFor<u16>, TupleUnion<(WA<Just<&'static [u8]>>, WA<Just<&'static [u8]>>, WA<Just<&'static [u8]>>, WA<Just<&'static [u8]>>)>) as Strategy>::Value) -> Utf8Error>
fn arbitrary_with(_args: Self::Parameters) -> Self::Strategy
[src]
impl<A: Arbitrary> Arbitrary for Arc<A>
[src]
type Parameters = A::Parameters
type Strategy = MapInto<A::Strategy, Self>
fn arbitrary_with(args: Self::Parameters) -> Self::Strategy
[src]
impl Arbitrary for AtomicBool
[src]
type Parameters = ()
type Strategy = SMapped<bool, Self>
fn arbitrary_with(_args: Self::Parameters) -> Self::Strategy
[src]
impl Arbitrary for AtomicIsize
[src]
type Parameters = ()
type Strategy = SMapped<isize, Self>
fn arbitrary_with(_args: Self::Parameters) -> Self::Strategy
[src]
impl Arbitrary for AtomicUsize
[src]
type Parameters = ()
type Strategy = SMapped<usize, Self>
fn arbitrary_with(_args: Self::Parameters) -> Self::Strategy
[src]
impl Arbitrary for Ordering
[src]
type Parameters = ()
type Strategy = TupleUnion<(WA<Just<Self>>, WA<Just<Self>>, WA<Just<Self>>, WA<Just<Self>>, WA<Just<Self>>)>
fn arbitrary_with(_args: Self::Parameters) -> Self::Strategy
[src]
impl Arbitrary for Args
[src]
type Parameters = ()
type Strategy = LazyJust<Self, fn() -> Self>
fn arbitrary_with(_args: Self::Parameters) -> Self::Strategy
[src]
impl Arbitrary for ArgsOs
[src]
type Parameters = ()
type Strategy = LazyJust<Self, fn() -> Self>
fn arbitrary_with(_args: Self::Parameters) -> Self::Strategy
[src]
impl Arbitrary for Vars
[src]
type Parameters = ()
type Strategy = LazyJust<Self, fn() -> Self>
fn arbitrary_with(_args: Self::Parameters) -> Self::Strategy
[src]
impl Arbitrary for VarsOs
[src]
type Parameters = ()
type Strategy = LazyJust<Self, fn() -> Self>
fn arbitrary_with(_args: Self::Parameters) -> Self::Strategy
[src]
impl Arbitrary for JoinPathsError
[src]
type Parameters = ()
type Strategy = LazyJust<Self, fn() -> Self>
fn arbitrary_with(_args: Self::Parameters) -> Self::Strategy
[src]
impl Arbitrary for VarError
[src]
type Parameters = ()
type Strategy = TupleUnion<(WA<Just<Self>>, WA<Map<BoxedStrategy<OsString>, fn(_: <BoxedStrategy<OsString> as Strategy>::Value) -> Self>>)>
fn arbitrary_with(_args: Self::Parameters) -> Self::Strategy
[src]
impl Arbitrary for CString
[src]
type Parameters = SizeRange
type Strategy = Map<VecStrategy<RangeInclusive<u8>>, fn(_: <VecStrategy<RangeInclusive<u8>> as Strategy>::Value) -> Self>
fn arbitrary_with(args: Self::Parameters) -> Self::Strategy
[src]
impl Arbitrary for OsString
[src]
type Parameters = <String as Arbitrary>::Parameters
type Strategy = MapInto<StrategyFor<String>, Self>
fn arbitrary_with(a: Self::Parameters) -> Self::Strategy
[src]
impl Arbitrary for Box<CStr>
[src]
type Parameters = SizeRange
type Strategy = MapInto<StrategyFor<CString>, Self>
fn arbitrary_with(a: Self::Parameters) -> Self::Strategy
[src]
impl Arbitrary for Box<OsStr>
[src]
type Parameters = <String as Arbitrary>::Parameters
type Strategy = MapInto<StrategyFor<OsString>, Self>
fn arbitrary_with(a: Self::Parameters) -> Self::Strategy
[src]
impl Arbitrary for FromBytesWithNulError
[src]
type Parameters = ()
type Strategy = SMapped<Option<u16>, Self>
fn arbitrary_with(_args: Self::Parameters) -> Self::Strategy
[src]
impl Arbitrary for IntoStringError
[src]
type Parameters = ()
type Strategy = Map<BoxedStrategy<Vec<u8>>, fn(_: <BoxedStrategy<Vec<u8>> as Strategy>::Value) -> Self>
fn arbitrary_with(_args: Self::Parameters) -> Self::Strategy
[src]
impl Arbitrary for DirBuilder
[src]
type Parameters = ()
type Strategy = SMapped<bool, Self>
fn arbitrary_with(_args: Self::Parameters) -> Self::Strategy
[src]
impl<A: Arbitrary + Read> Arbitrary for BufReader<A>
[src]
type Parameters = A::Parameters
type Strategy = SMapped<(A, Option<u16>), Self>
fn arbitrary_with(args: Self::Parameters) -> Self::Strategy
[src]
impl<A: Arbitrary + Write> Arbitrary for BufWriter<A>
[src]
type Parameters = A::Parameters
type Strategy = SMapped<(A, Option<u16>), Self>
fn arbitrary_with(args: Self::Parameters) -> Self::Strategy
[src]
impl<A: Arbitrary + Write> Arbitrary for LineWriter<A>
[src]
type Parameters = A::Parameters
type Strategy = SMapped<(A, Option<u16>), Self>
fn arbitrary_with(args: Self::Parameters) -> Self::Strategy
[src]
impl<A: Read + Arbitrary, B: Read + Arbitrary> Arbitrary for Chain<A, B>
[src]
type Parameters = (A::Parameters, B::Parameters)
type Strategy = SMapped<(A, B), Self>
fn arbitrary_with(args: Self::Parameters) -> Self::Strategy
[src]
impl<A: Arbitrary> Arbitrary for Cursor<A>
[src]
type Parameters = A::Parameters
type Strategy = SMapped<A, Self>
fn arbitrary_with(args: Self::Parameters) -> Self::Strategy
[src]
impl Arbitrary for Empty
[src]
type Parameters = ()
type Strategy = LazyJust<Self, fn() -> Self>
fn arbitrary_with(_args: Self::Parameters) -> Self::Strategy
[src]
impl Arbitrary for Sink
[src]
type Parameters = ()
type Strategy = LazyJust<Self, fn() -> Self>
fn arbitrary_with(_args: Self::Parameters) -> Self::Strategy
[src]
impl Arbitrary for Stderr
[src]
type Parameters = ()
type Strategy = LazyJust<Self, fn() -> Self>
fn arbitrary_with(_args: Self::Parameters) -> Self::Strategy
[src]
impl Arbitrary for Stdin
[src]
type Parameters = ()
type Strategy = LazyJust<Self, fn() -> Self>
fn arbitrary_with(_args: Self::Parameters) -> Self::Strategy
[src]
impl Arbitrary for Stdout
[src]
type Parameters = ()
type Strategy = LazyJust<Self, fn() -> Self>
fn arbitrary_with(_args: Self::Parameters) -> Self::Strategy
[src]
impl<A: Arbitrary + BufRead> Arbitrary for Lines<A>
[src]
type Parameters = A::Parameters
type Strategy = SMapped<A, Self>
fn arbitrary_with(args: Self::Parameters) -> Self::Strategy
[src]
impl Arbitrary for Repeat
[src]
type Parameters = ()
type Strategy = SMapped<u8, Self>
fn arbitrary_with(_args: Self::Parameters) -> Self::Strategy
[src]
impl<A: BufRead + Arbitrary> Arbitrary for Split<A>
[src]
type Parameters = A::Parameters
type Strategy = SMapped<(A, u8), Self>
fn arbitrary_with(args: Self::Parameters) -> Self::Strategy
[src]
impl<A: Read + Arbitrary> Arbitrary for Take<A>
[src]
type Parameters = A::Parameters
type Strategy = SMapped<(A, u64), Self>
fn arbitrary_with(args: Self::Parameters) -> Self::Strategy
[src]
impl Arbitrary for ErrorKind
[src]
type Parameters = ()
type Strategy = Union<Just<Self>>
fn arbitrary_with(_args: Self::Parameters) -> Self::Strategy
[src]
impl Arbitrary for SeekFrom
[src]
type Parameters = ()
type Strategy = TupleUnion<(WA<SMapped<u64, SeekFrom>>, WA<SMapped<i64, SeekFrom>>, WA<SMapped<i64, SeekFrom>>)>
fn arbitrary_with(_args: Self::Parameters) -> Self::Strategy
[src]
impl Arbitrary for Error
[src]
type Parameters = ()
type Strategy = SMapped<(ErrorKind, Option<String>), Self>
fn arbitrary_with(_args: Self::Parameters) -> Self::Strategy
[src]
impl Arbitrary for AddrParseError
[src]
type Parameters = ()
type Strategy = Just<Self>
fn arbitrary_with(_args: Self::Parameters) -> Self::Strategy
[src]
impl Arbitrary for Ipv4Addr
[src]
type Parameters = ()
type Strategy = TupleUnion<(WA<Just<Self>>, WA<Just<Self>>, WA<MapInto<StrategyFor<u32>, Self>>)>
fn arbitrary_with(_args: Self::Parameters) -> Self::Strategy
[src]
impl Arbitrary for Ipv6Addr
[src]
type Parameters = ()
type Strategy = TupleUnion<(WA<SMapped<Ipv4Addr, Self>>, WA<MapInto<StrategyFor<[u16; 8]>, Self>>)>
fn arbitrary_with(_args: Self::Parameters) -> Self::Strategy
[src]
impl Arbitrary for SocketAddrV4
[src]
type Parameters = ()
type Strategy = SMapped<(Ipv4Addr, u16), Self>
fn arbitrary_with(_args: Self::Parameters) -> Self::Strategy
[src]
impl Arbitrary for SocketAddrV6
[src]
type Parameters = ()
type Strategy = SMapped<(Ipv6Addr, u16, u32, u32), Self>
fn arbitrary_with(_args: Self::Parameters) -> Self::Strategy
[src]
impl Arbitrary for IpAddr
[src]
type Parameters = ()
type Strategy = TupleUnion<(WA<MapInto<StrategyFor<Ipv4Addr>, Self>>, WA<MapInto<StrategyFor<Ipv6Addr>, Self>>)>
fn arbitrary_with(_args: Self::Parameters) -> Self::Strategy
[src]
impl Arbitrary for Shutdown
[src]
type Parameters = ()
type Strategy = TupleUnion<(WA<Just<Self>>, WA<Just<Self>>, WA<Just<Self>>)>
fn arbitrary_with(_args: Self::Parameters) -> Self::Strategy
[src]
impl Arbitrary for SocketAddr
[src]
type Parameters = ()
type Strategy = TupleUnion<(WA<MapInto<StrategyFor<SocketAddrV4>, Self>>, WA<MapInto<StrategyFor<SocketAddrV6>, Self>>)>
fn arbitrary_with(_args: Self::Parameters) -> Self::Strategy
[src]
impl<A: Arbitrary> Arbitrary for AssertUnwindSafe<A>
[src]
type Parameters = A::Parameters
type Strategy = SMapped<A, Self>
fn arbitrary_with(args: Self::Parameters) -> Self::Strategy
[src]
impl Arbitrary for StripPrefixError
[src]
type Parameters = ()
type Strategy = Just<Self>
fn arbitrary_with(_args: Self::Parameters) -> Self::Strategy
[src]
impl Arbitrary for String
[src]
type Parameters = StringParam
type Strategy = &'static str
fn arbitrary_with(args: Self::Parameters) -> Self::Strategy
[src]
Panics
This implementation panics if the input is not a valid regex proptest can handle.