ZeroErr
|
Domain class for generating random values of a specific type. More...
#include <domain.h>
Public Member Functions | |
virtual | ~Domain ()=default |
virtual CorpusType | GetRandomCorpus (Rng &rng) const =0 |
virtual ValueType | GetRandomValue (Rng &rng) const |
virtual CorpusType | FromValue (const ValueType &v) const =0 |
virtual ValueType | GetValue (const CorpusType &v) const =0 |
virtual CorpusType | ParseCorpus (IRObject v) const |
virtual IRObject | SerializeCorpus (const CorpusType &v) const |
virtual void | Mutate (Rng &rng, CorpusType &v, bool only_shrink=false) const =0 |
Domain class for generating random values of a specific type.
ValueType | The type of the value to generate. |
CorpusType | The type of the corpus stored in the domain. Here is an example. If you want to generate an list of intergers, but will store the list in a vector, then ValueType will be std::list<int> and CorpusType will be std::vector<int>. |
|
virtualdefault |
|
pure virtual |
Implemented in zeroerr::ElementOf< T >, zeroerr::SequenceContainerOf< T, InnerDomain >, zeroerr::SequenceContainerOf< T, Arbitrary< T::value_type > >, zeroerr::AssociativeContainerOf< T, InnerDomain >, zeroerr::Arbitrary< T, is_string< T > >, zeroerr::AggregateOf< T, Inner >, zeroerr::AggregateOf< std::tuple< std::remove_const< T >::type... > >, zeroerr::AggregateOf< std::pair< std::remove_const< T >::type, std::remove_const< U >::type > >, and zeroerr::DomainConvertable< ValueType, CorpusType >.
|
pure virtual |
Implemented in zeroerr::InRange< T >, zeroerr::SequenceContainerOf< T, InnerDomain >, zeroerr::SequenceContainerOf< T, Arbitrary< T::value_type > >, zeroerr::AssociativeContainerOf< T, InnerDomain >, zeroerr::Arbitrary< T, is_string< T > >, zeroerr::Arbitrary< T, is_float_point< T > >, zeroerr::Arbitrary< T, is_signed_int< T > >, zeroerr::Arbitrary< T, is_unsigned_int< T > >, zeroerr::Arbitrary< bool >, zeroerr::AggregateOf< T, Inner >, zeroerr::AggregateOf< std::tuple< std::remove_const< T >::type... > >, and zeroerr::AggregateOf< std::pair< std::remove_const< T >::type, std::remove_const< U >::type > >.
|
inlinevirtual |
|
pure virtual |
Implemented in zeroerr::ElementOf< T >.
|
pure virtual |
Implemented in zeroerr::ElementOf< T >.
|
inlinevirtual |
|
inlinevirtual |