Class DefaultCodeDelegate

    • Field Detail

      • RND

        protected final Random RND
    • Constructor Detail

      • DefaultCodeDelegate

        public DefaultCodeDelegate()
    • Method Detail

      • random

        public final double random​(double max)
        Return a random number between zero and max (exclusive)
        Specified by:
        random in interface DefaultDelegateAPI
        Parameters:
        max - the upper bound of the range
        Returns:
      • random

        public final double random​(double min,
                                   double max)
        Return a random number between min (inclusive) and max (exclusive)
        Specified by:
        random in interface DefaultDelegateAPI
        Parameters:
        min - the lower bound of the range
        max - the upper bound of the range
        Returns:
      • randomOf

        public final double randomOf​(double... values)
        Return a random element from an array of values.
        Specified by:
        randomOf in interface DefaultDelegateAPI
        Parameters:
        values - list of values, may not be empty
        Returns:
        random element
      • randomOf

        public final int randomOf​(int... values)
        Return a random element from an array of values.
        Specified by:
        randomOf in interface DefaultDelegateAPI
        Parameters:
        values - list of values, may not be empty
        Returns:
        random element
      • randomOf

        public final String randomOf​(String... values)
        Return a random element from an array of values.
        Specified by:
        randomOf in interface DefaultDelegateAPI
        Parameters:
        values - list of values, may not be empty
        Returns:
        random element
      • noise

        @Deprecated
        public double noise​(double x)
        Deprecated.
        Computes the Perlin noise function value at point x.
        Parameters:
        x -
        Returns:
      • noise

        @Deprecated
        public double noise​(double x,
                            double y)
        Deprecated.
        Computes the Perlin noise function value at the point x, y.
        Parameters:
        x -
        y -
        Returns:
      • noise

        @Deprecated
        public double noise​(double x,
                            double y,
                            double z)
        Deprecated.
        Computes the Perlin noise function value at x, y, z.
        Parameters:
        x -
        z -
        y -
        Returns:
      • noiseDetail

        @Deprecated
        public void noiseDetail​(int lod)
        Deprecated.
        Parameters:
        lod -
      • noiseDetail

        @Deprecated
        public void noiseDetail​(int lod,
                                double falloff)
        Deprecated.
        Parameters:
        lod -
        falloff -
      • noiseSeed

        @Deprecated
        public void noiseSeed​(long what)
        Deprecated.
        Parameters:
        what -
      • arrayCopy

        @Deprecated
        public void arrayCopy​(Object src,
                              int srcPosition,
                              Object dst,
                              int dstPosition,
                              int length)
        Deprecated.
        Copies an array (or part of an array) to another array. The src array is copied to the dst array, beginning at the position specified by srcPos and into the position specified by dstPos. The number of elements to copy is determined by length.
        Parameters:
        src -
        srcPosition -
        dst -
        dstPosition -
        length -
      • arrayCopy

        @Deprecated
        public void arrayCopy​(Object src,
                              Object dst,
                              int length)
        Deprecated.
        Copies an array (or part of an array) to another array. The src array is copied to the dst array. The number of elements to copy is determined by length.
        Parameters:
        src -
        dst -
        length -
      • arrayCopy

        @Deprecated
        public void arrayCopy​(Object src,
                              Object dst)
        Deprecated.
        Copies an array to another array. The src array is copied to the dst array.
        Parameters:
        src -
        dst -