boost::icl::Law< SubType, InputTypes, OutputTypes > Class Template Reference

An abstract class template Law. More...

List of all members.

Public Member Functions

bool debug_holds ()
std::string formula () const
 A formula for the law.
void getInputInstance (input_tuple &inVars) const
template<unsigned int index>
Loki::TL::TypeAt< InputTypes,
index >::Result 
getInputValue () const
void getInstance (input_tuple &inVars, output_tuple &outVars) const
void getOutputInstance (output_tuple &outVars) const
template<unsigned int index>
Loki::TL::TypeAt< OutputTypes,
index >::Result 
getOutputValue () const
bool holds ()
std::string name () const
 The name of the law.
bool operator< (const Law &rhs) const
bool operator== (const Law &rhs) const
template<unsigned int index>
Loki::TL::TypeAt< InputTypes,
index >::Result 
setInputValue (const typename Loki::TL::TypeAt< InputTypes, index >::Result &value)
void setInstance (const input_tuple &inVars)
template<unsigned int index>
Loki::TL::TypeAt< OutputTypes,
index >::Result 
setOutputValue (const typename Loki::TL::TypeAt< OutputTypes, index >::Result &value)
size_t size () const
std::string typeString () const
 A string that represents the Laws type instantiation.

Detailed Description

template<class SubType, typename InputTypes, typename OutputTypes>
class boost::icl::Law< SubType, InputTypes, OutputTypes >

An abstract class template Law.

A Law can hold for a given set of variables. A Law together with the set of input variables is an instance of the law. The evaluation of the law results in a set of output variables. Output variables hold interim and final results of the evaluation of the law.


Member Function Documentation

template<class SubType , typename InputTypes , typename OutputTypes >
bool boost::icl::Law< SubType, InputTypes, OutputTypes >::holds (  )  [inline]

Function holds yields true if the law holds for a given instantiation of the input variables.

template<class SubType , typename InputTypes , typename OutputTypes >
bool boost::icl::Law< SubType, InputTypes, OutputTypes >::debug_holds (  )  [inline]

Function debug_holds is called at the end of a series of randomly generated tests on the smallest law instantiation that violates the law. Specific laws derived from class Law shall be coded to provide informations useful for debugging.

template<class SubType , typename InputTypes , typename OutputTypes >
void boost::icl::Law< SubType, InputTypes, OutputTypes >::setInstance ( const input_tuple &  inVars  )  [inline]

Set input variables for a law.

template<class SubType , typename InputTypes , typename OutputTypes >
void boost::icl::Law< SubType, InputTypes, OutputTypes >::getInstance ( input_tuple &  inVars,
output_tuple &  outVars 
) const [inline]

Get input and output variables.

template<class SubType , typename InputTypes , typename OutputTypes >
void boost::icl::Law< SubType, InputTypes, OutputTypes >::getInputInstance ( input_tuple &  inVars  )  const [inline]

Get input variables.

template<class SubType , typename InputTypes , typename OutputTypes >
void boost::icl::Law< SubType, InputTypes, OutputTypes >::getOutputInstance ( output_tuple &  outVars  )  const [inline]

Get output variables.

template<class SubType , typename InputTypes , typename OutputTypes >
size_t boost::icl::Law< SubType, InputTypes, OutputTypes >::size (  )  const [inline]

Get the size of a laws instantiation, that is a function of it's input variables. The size function is used to filter small and simple violations of laws in order to facilitate debugging.

template<class SubType , typename InputTypes , typename OutputTypes >
bool boost::icl::Law< SubType, InputTypes, OutputTypes >::operator== ( const Law< SubType, InputTypes, OutputTypes > &  rhs  )  const [inline]

A size equivalence on laws.

template<class SubType , typename InputTypes , typename OutputTypes >
bool boost::icl::Law< SubType, InputTypes, OutputTypes >::operator< ( const Law< SubType, InputTypes, OutputTypes > &  rhs  )  const [inline]

A size order on laws. This ordering servers filter small and simple law instances that violate the law.

template<class SubType , typename InputTypes , typename OutputTypes >
std::string boost::icl::Law< SubType, InputTypes, OutputTypes >::name (  )  const [inline]

The name of the law.

template<class SubType , typename InputTypes , typename OutputTypes >
std::string boost::icl::Law< SubType, InputTypes, OutputTypes >::formula (  )  const [inline]

A formula for the law.

template<class SubType , typename InputTypes , typename OutputTypes >
std::string boost::icl::Law< SubType, InputTypes, OutputTypes >::typeString (  )  const [inline]

A string that represents the Laws type instantiation.

template<class SubType , typename InputTypes , typename OutputTypes >
template<unsigned int index>
Loki::TL::TypeAt<InputTypes, index>::Result boost::icl::Law< SubType, InputTypes, OutputTypes >::setInputValue ( const typename Loki::TL::TypeAt< InputTypes, index >::Result &  value  )  [inline]

Set a value for a laws input variable, indicated by it's in the tuple of input variables

template<class SubType , typename InputTypes , typename OutputTypes >
template<unsigned int index>
Loki::TL::TypeAt<InputTypes, index>::Result boost::icl::Law< SubType, InputTypes, OutputTypes >::getInputValue (  )  const [inline]

Get the value for a laws input variable, indicated by it's in the tuple of input variables

template<class SubType , typename InputTypes , typename OutputTypes >
template<unsigned int index>
Loki::TL::TypeAt<OutputTypes, index>::Result boost::icl::Law< SubType, InputTypes, OutputTypes >::setOutputValue ( const typename Loki::TL::TypeAt< OutputTypes, index >::Result &  value  )  [inline]

Set a value for a laws output variable, indicated by it's in the tuple of output variables

template<class SubType , typename InputTypes , typename OutputTypes >
template<unsigned int index>
Loki::TL::TypeAt<OutputTypes, index>::Result boost::icl::Law< SubType, InputTypes, OutputTypes >::getOutputValue (  )  const [inline]

Get the value for a laws output variable, indicated by it's in the tuple of output variables


The documentation for this class was generated from the following file:

Generated by  doxygen 1.6.2