GKRandomDistribution.GetNextInt 方法

定义

重载

GetNextInt()

返回分布边界中的整数。

GetNextInt(nuint)

返回分布边界内的整数,但不大于 upperBound

GetNextInt()

返回分布边界中的整数。

[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

返回

System.System.IntPtr System.nativeint

实现

属性

适用于

GetNextInt(nuint)

返回分布边界内的整数,但不大于 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

参数

upperBound
System.System.UIntPtr System.unativeint

返回

System.System.UIntPtr System.unativeint

实现

属性

适用于