文档

Unity Engine

Unity Engine

EnumToInt<T>(T)

Gets the integer representation of an enum value without boxing.
阅读时间1 分钟最后更新于 1 个月前

Definition

public static int EnumToInt<T>(T enumValue) where T : struct, IConvertible

Parameters

enumValue

T
Enum value to convert.

Returns

Type

Description

intReturns the integer representation of the enum value.