shawn::ConstantEdgeRandom Class Reference

#include <constant_edge_random.h>

Inheritance diagram for shawn::ConstantEdgeRandom:

Inheritance graph
[legend]
Collaboration diagram for shawn::ConstantEdgeRandom:

Collaboration graph
[legend]

List of all members.

Public Types

typedef DynamicNodeArray< int > base_type

Public Member Functions

 ConstantEdgeRandom (World &, const std::string &tag="")
virtual ~ConstantEdgeRandom ()
double operator() (const Node &, const Node &, bool directed=false) const throw ()
virtual void node_added (Node &v) throw ()
 Is called whenever a node gets added to the world.

Protected Member Functions

virtual void assign_seed (Node &) throw ()


Member Typedef Documentation


Constructor & Destructor Documentation

shawn::ConstantEdgeRandom::ConstantEdgeRandom ( World ,
const std::string &  tag = "" 
)

constructs a ConstantEdgeRandom. If tag is not empty, it will save write state information to node tags (with the given name) so that the random values survive a save&load cycle

virtual shawn::ConstantEdgeRandom::~ConstantEdgeRandom (  )  [virtual]


Member Function Documentation

double shawn::ConstantEdgeRandom::operator() ( const Node ,
const Node ,
bool  directed = false 
) const throw ()

returns a number uniformly distributed between 0.0 and 1.0 (both inclusive). For the same node pair, it always returns the same number. If directed==true, ()(u,v) and ()(v,u) are different.

virtual void shawn::ConstantEdgeRandom::node_added ( Node  )  throw () [virtual]

Is called whenever a node gets added to the world.

Reimplemented from shawn::DynamicNodeArray< int >.

virtual void shawn::ConstantEdgeRandom::assign_seed ( Node  )  throw () [protected, virtual]


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

Generated on Tue Feb 7 00:01:01 2012 for Shawn by  doxygen 1.5.6