Search Results for

    Show / Hide Table of Contents

    Class RandomDefault

    Default random number generator, that is consistent across the different APIs.

    Inheritance
    System.Object
    RandomDefault
    Implements
    IRandom
    Inherited Members
    System.Object.Equals(System.Object)
    System.Object.Equals(System.Object, System.Object)
    System.Object.GetHashCode()
    System.Object.GetType()
    System.Object.MemberwiseClone()
    System.Object.ReferenceEquals(System.Object, System.Object)
    System.Object.ToString()
    Namespace: BayesServer
    Assembly: BayesServer.dll
    Syntax
    public sealed class RandomDefault : IRandom

    Constructors

    RandomDefault()

    Initializes a new instance of the RandomDefault class, using a seed generated from the system clock.

    Declaration
    public RandomDefault()

    RandomDefault(Int32)

    Initializes a new instance of the RandomDefault class, with a specified seed.

    Declaration
    public RandomDefault(int seed)
    Parameters
    Type Name Description
    System.Int32 seed

    Methods

    NextDouble()

    Generates a random floating-point number that is greater than or equal to 0.0, and less than 1.0.

    Declaration
    public double NextDouble()
    Returns
    Type Description
    System.Double

    NextInt(Int32, Int32)

    Generates a random integer between [minValue..maxValue).

    Declaration
    public int NextInt(int minValue, int maxValue)
    Parameters
    Type Name Description
    System.Int32 minValue

    the least legal value for the Random number.

    System.Int32 maxValue

    One greater than the greatest legal return value.

    Returns
    Type Description
    System.Int32

    Random int between [minValue..maxValue).

    Implements

    IRandom
    In This Article
    Back to top Copyright Bayes Server Ltd. All rights Reserved.