PHP 8.4.1 Released!

La classe Random\Randomizer

(PHP 8 >= 8.2.0)

Introduction

Fournit une API de haut niveau pour l'aléatoire fourni par Random\Engine.

Synopsis de la classe

final class Random\Randomizer {
/* Propriétés */
public readonly Random\Engine $engine;
/* Méthodes */
public __construct(?Random\Engine $engine = null)
public getBytes(int $length): string
public getBytesFromString(string $string, int $length): string
public getFloat(float $min, float $max, Random\IntervalBoundary $boundary = Random\IntervalBoundary::ClosedOpen): float
public getInt(int $min, int $max): int
public nextFloat(): float
public nextInt(): int
public pickArrayKeys(array $array, int $num): array
public __serialize(): array
public shuffleArray(array $array): array
public shuffleBytes(string $bytes): string
public __unserialize(array $data): void
}

Propriétés

engine

Source d'aléatoire de bas niveau pour les méthodes de Random\Randomizer.

Sommaire

add a note

User Contributed Notes

There are no user contributed notes for this page.
To Top