Class DistributionContainer
java.lang.Object
random.DistributionContainer
Title:Distribution Container
Description: Data structure that stores a nested distribution
- Author:
- Peter Parapatics Date: 17-dec-1007
-
Field Summary
Fields -
Constructor Summary
ConstructorsConstructorDescriptionDistributionContainer(StorableDistribution distribution, Parameter parameter) Constructs a Distribution Container with a given distribution and a parameter -
Method Summary
Modifier and TypeMethodDescriptionGet the discrete distribution stored in the containerGet the continuous distribution stored in the containerGet method for the distribution parameter
-
Field Details
-
distribution
-
parameter
-
-
Constructor Details
-
DistributionContainer
Constructs a Distribution Container with a given distribution and a parameter- Parameters:
distribution- the distribution to be storedparameter- the parameter of the distribution
-
-
Method Details
-
getDistribution
Get the continuous distribution stored in the container- Returns:
- the distribution stored in the container
- Throws:
ClassCastException- if the distribution stored is not a continuous distribution
-
getDiscreteDistribution
Get the discrete distribution stored in the container- Returns:
- the distribution stored in the container
- Throws:
ClassCastException- if the distribution stored is not a discrete distribution
-
getParameter
Get method for the distribution parameter- Returns:
- the parameter belonging to the distribution
-