constructors for passing the bounder to super class
This commit is contained in:
parent
5dc8a1a8fe
commit
c8d9acd0a5
1 changed files with 14 additions and 1 deletions
|
|
@ -18,10 +18,23 @@
|
||||||
* This class uses the Uniform distribution parameters (bounds) to return
|
* This class uses the Uniform distribution parameters (bounds) to return
|
||||||
* a random position used for population sampling.
|
* a random position used for population sampling.
|
||||||
*/
|
*/
|
||||||
template < typename EOT >
|
template < typename EOT, class D=doUniform<EOT> >
|
||||||
class doSamplerUniform : public doSampler< doUniform< EOT > >
|
class doSamplerUniform : public doSampler< doUniform< EOT > >
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
|
|
||||||
|
typedef D Distrib;
|
||||||
|
|
||||||
|
doSamplerUniform(doBounder< EOT > & bounder)
|
||||||
|
: doSampler< doUniform<EOT> >(bounder)
|
||||||
|
{}
|
||||||
|
|
||||||
|
/*
|
||||||
|
doSamplerUniform()
|
||||||
|
: doSampler< doUniform<EOT> >()
|
||||||
|
{}
|
||||||
|
*/
|
||||||
|
|
||||||
EOT sample( doUniform< EOT >& distrib )
|
EOT sample( doUniform< EOT >& distrib )
|
||||||
{
|
{
|
||||||
unsigned int size = distrib.size();
|
unsigned int size = distrib.size();
|
||||||
|
|
|
||||||
Reference in a new issue