Main Page | Modules | Namespace List | Class Hierarchy | Alphabetical List | Compound List | File List | Namespace Members | Compound Members | File Members | Related Pages

Utility constructs for Vaucanson


Files

file  selectors.hh
 Definition of type argument macros.

file  unique.hh
 Declarations for the type canonicalization tools.

file  static.hh
 Definition of metaprogrammation helpers.

file  random.hh
 Definition of random generators.

file  contract.hh
 Definition of contract macros.

file  limits.hh
 Wrapper about the numeric limits for Vaucanson.


Namespaces

namespace  utility
 In Vaucanson, several types of contracts can be placed in the library code.


Modules

Contract checking for Vaucansn

Compounds

struct  remove_reference
 Turn a reference type into its corresponding plain type. More...

struct  remove_const
 Turn a const type into its corresponding mutable type. More...

struct  static_if
 Choose between two types or values depending on a constant boolean. More...

struct  static_eq
 Test for equality between two types. More...

struct  static_pow
 Static exponentiation. More...

struct  static_pow_minus_one
 Static exponentiation, result minus one. More...

class  SupportIterator
 Iterator over the Support generic class. More...

class  Support< std::map< U, T > >
 Support<map<U, T> > is a const adapter of std::map to container. More...

class  SparseIterator
 SparseIterator is an iterator over range except some points. More...

class  SparseInterval
 Container over a sparse integer range. More...

class  SelfIterator
 SelfIterator is an iterator which is also a container. More...


Defines

#define SELECT(T)   (*(const T*)0)
 Type argument for types with no commas (simple or 1-par templates).

#define SELECT2(T1, T2)   (*(const T1 , T2 *)0)
 Type argument for types with one comma (2-parameters templates).

#define SELECT3(T1, T2, T3)   (*(const T1 , T2, T3 *)0)
 Type argument for types with two commas (3-parameters templates).

#define SELECT4(T1, T2, T3, T4)   (*(const T1 , T2, T3, T4 *)0)
 Type argument for types with three commas (4-parameters templates).

#define SELECTOR(T)   const T &
 Type formal argument for types with no commas (simple or 1-par templates).

#define SELECTOR2(T1, T2)   const T1 , T2 &
 Type formal argument for types with one comma (2-parameters templates).

#define SELECTOR3(T1, T2, T3)   const T1 , T2, T3 &
 Type formal argument for types with two commas (3-parameters templates).

#define SELECTOR4(T1, T2, T3, T4)   const T1 , T2, T3, T4 &
 Type formal argument for types with three commas (4-parameters templates).


Functions

template<typename T> T generate ()
 Generate a random value.

template<typename T> T generate (T min, T max)
 Generate a random value between bounds.

template<> char generate< char > ()
 Generate a random character.

template<> char generate< char > (char min, char max)
 Generate a random character between bounds.

char generate_letter ()
 Generate a random lowercase letter.

char generate_digit ()
 Generate a random digit.

template<> bool generate< bool > ()
 Generate a random Boolean.

template<> int generate< int > ()
 Generate a random integer.

template<> int generate< int > (int min, int max)
 Generate a random integer between two bounds.

template<> float generate< float > ()
 Generate a random float between 0 and 1.

template<typename T> const T & get (const T &)
 The canonicalization operator.

template<typename T> const T * get (const T *)
 Version of the canonicalization operator for pointers.


Function Documentation

T generate min,
max
 

Generate a random value between bounds.

This function returns a value between min and max (inclusive).

const T& get const T &   ) 
 

The canonicalization operator.

This operator uses the unique_map structure to retrieve the unique instance equal to the given value.

See also:
unique_map


Generated on Fri Jul 11 19:43:39 2003 for Vaucanson by doxygen 1.3.2