SST  12.0.0
StructuralSimulationToolkit
distrib.h
1 // Copyright 2009-2022 NTESS. Under the terms
2 // of Contract DE-NA0003525 with NTESS, the U.S.
3 // Government retains certain rights in this software.
4 //
5 // Copyright (c) 2009-2022, NTESS
6 // All rights reserved.
7 //
8 // This file is part of the SST software package. For license
9 // information, see the LICENSE file in the top level directory of the
10 // distribution.
11 
12 #ifndef SST_CORE_RNG_DISTRIB_H
13 #define SST_CORE_RNG_DISTRIB_H
14 
15 namespace SST {
16 namespace RNG {
17 
18 /**
19  * \class RandomDistribution
20  * Base class of statistical distributions in SST.
21  */
23 {
24 
25 public:
26  /**
27  Obtains the next double from the distribution
28  \return The next double in the distribution being sampled
29  */
30  virtual double getNextDouble() = 0;
31 
32  /**
33  Destroys the distribution
34  */
35  virtual ~RandomDistribution() {};
36 
37  /**
38  Creates the base (abstract) class of a distribution
39  */
41 };
42 
43 using SSTRandomDistribution = SST::RNG::RandomDistribution;
44 
45 } // namespace RNG
46 } // namespace SST
47 
48 #endif // SST_CORE_RNG_DISTRIB_H
virtual ~RandomDistribution()
Destroys the distribution.
Definition: distrib.h:35
virtual double getNextDouble()=0
Obtains the next double from the distribution.
RandomDistribution()
Creates the base (abstract) class of a distribution.
Definition: distrib.h:40
Base class of statistical distributions in SST.
Definition: distrib.h:22