Random.NextInt64 Méthode
Définition
Important
Certaines informations portent sur la préversion du produit qui est susceptible d’être en grande partie modifiée avant sa publication. Microsoft exclut toute garantie, expresse ou implicite, concernant les informations fournies ici.
Surcharges
| Nom | Description |
|---|---|
| NextInt64() |
Retourne un entier aléatoire non négatif. |
| NextInt64(Int64) |
Retourne un entier aléatoire non négatif inférieur au maximum spécifié. |
| NextInt64(Int64, Int64) |
Retourne un entier aléatoire qui se trouve dans une plage spécifiée. |
NextInt64()
- Source:
- Random.cs
- Source:
- Random.cs
- Source:
- Random.cs
- Source:
- Random.cs
- Source:
- Random.cs
Retourne un entier aléatoire non négatif.
public:
virtual long NextInt64();
public virtual long NextInt64();
abstract member NextInt64 : unit -> int64
override this.NextInt64 : unit -> int64
Public Overridable Function NextInt64 () As Long
Retours
Entier signé 64 bits supérieur ou égal à 0 et inférieur à Int64.MaxValue.
S’applique à
NextInt64(Int64)
- Source:
- Random.cs
- Source:
- Random.cs
- Source:
- Random.cs
- Source:
- Random.cs
- Source:
- Random.cs
Retourne un entier aléatoire non négatif inférieur au maximum spécifié.
public:
virtual long NextInt64(long maxValue);
public virtual long NextInt64(long maxValue);
abstract member NextInt64 : int64 -> int64
override this.NextInt64 : int64 -> int64
Public Overridable Function NextInt64 (maxValue As Long) As Long
Paramètres
- maxValue
- Int64
Limite supérieure exclusive du nombre aléatoire à générer.
maxValue doit être supérieur ou égal à 0.
Retours
Entier signé 64 bits supérieur ou égal à 0, et inférieur maxValueà ; autrement dit, la plage de valeurs de retour inclut généralement 0, mais pas maxValue. Toutefois, si maxValue la valeur est égale à 0, maxValue est retournée.
Exceptions
maxValue est inférieur à 0.
S’applique à
NextInt64(Int64, Int64)
- Source:
- Random.cs
- Source:
- Random.cs
- Source:
- Random.cs
- Source:
- Random.cs
- Source:
- Random.cs
Retourne un entier aléatoire qui se trouve dans une plage spécifiée.
public:
virtual long NextInt64(long minValue, long maxValue);
public virtual long NextInt64(long minValue, long maxValue);
abstract member NextInt64 : int64 * int64 -> int64
override this.NextInt64 : int64 * int64 -> int64
Public Overridable Function NextInt64 (minValue As Long, maxValue As Long) As Long
Paramètres
- minValue
- Int64
Limite inférieure inclusive du nombre aléatoire retourné.
- maxValue
- Int64
Limite supérieure exclusive du nombre aléatoire retourné.
maxValue doit être supérieur ou égal à minValue.
Retours
Entier signé 64 bits supérieur ou égal à et inférieur à minValue ; autrement dit, la plage de valeurs de retour inclutminValue, mais pas maxValue.maxValue Si minValue est égal maxValueà , minValue est retourné.
Exceptions
minValue est supérieur à maxValue.