Randoms


Object Hierarchy:

Object hierarchy for Randoms

Description:

public class Randoms : Object

Random utility methods.

This class offers common random operations for quick application logic: bounded integers, doubles, and in-place array shuffling.

Example:

    var idResult = Randoms.nextInt (1000);
if (idResult.isOk ()) {
int id = idResult.unwrap ();
}
double ratio = Randoms.nextDouble ();

int[] values = { 1, 2, 3, 4 };
Randoms.shuffle<int> (values);


Namespace: Vala.Lang
Package: Valacore

Content:

Static methods:

Creation methods:

Inherited Members:

All known members inherited from class GLib.Object