Upravit

Sdílet prostřednictvím


GKRandomSource.GetNextInt Method

Definition

Overloads

GetNextInt()

Returns a random integer, in the range [F:System.Int32.MinValue, F:System.Int32.MaxValue].

GetNextInt(nuint)

Returns a random integer that is less than upperBound.

GetNextInt()

Returns a random integer, in the range [F:System.Int32.MinValue, F:System.Int32.MaxValue].

[Foundation.Export("nextInt")]
[ObjCRuntime.Introduced(ObjCRuntime.PlatformName.iOS, 9, 0, ObjCRuntime.PlatformArchitecture.All, null)]
[ObjCRuntime.Introduced(ObjCRuntime.PlatformName.MacOSX, 10, 11, ObjCRuntime.PlatformArchitecture.Arch64, null)]
public virtual nint GetNextInt ();
abstract member GetNextInt : unit -> nint
override this.GetNextInt : unit -> nint

Returns

System.System.IntPtr System.nativeint

Implements

Attributes

Applies to

GetNextInt(nuint)

Returns a random integer that is less than upperBound.

[Foundation.Export("nextIntWithUpperBound:")]
[ObjCRuntime.Introduced(ObjCRuntime.PlatformName.iOS, 9, 0, ObjCRuntime.PlatformArchitecture.All, null)]
[ObjCRuntime.Introduced(ObjCRuntime.PlatformName.MacOSX, 10, 11, ObjCRuntime.PlatformArchitecture.Arch64, null)]
public virtual nuint GetNextInt (nuint upperBound);
abstract member GetNextInt : nuint -> nuint
override this.GetNextInt : nuint -> nuint

Parameters

upperBound
System.System.UIntPtr System.unativeint

Returns

System.System.UIntPtr System.unativeint

Implements

Attributes

Applies to