共用方式為


Enum Constructors

Definition

Overloads

Enum(IntPtr, JniHandleOwnership)

A constructor used when creating managed representations of JNI objects; called by the runtime.

Enum(String, Int32)

Sole constructor.

Enum(IntPtr, JniHandleOwnership)

A constructor used when creating managed representations of JNI objects; called by the runtime.

protected Enum (IntPtr javaReference, Android.Runtime.JniHandleOwnership transfer);
new Java.Lang.Enum : nativeint * Android.Runtime.JniHandleOwnership -> Java.Lang.Enum

Parameters

javaReference
IntPtr

nativeint

A IntPtrcontaining a Java Native Interface (JNI) object reference.

transfer
JniHandleOwnership

A JniHandleOwnershipindicating how to handle javaReference

Remarks

Portions of this page are modifications based on work created and shared by the Android Open Source Project and used according to terms described in the Creative Commons 2.5 Attribution License.

Applies to

Enum(String, Int32)

Sole constructor.

[Android.Runtime.Register(".ctor", "(Ljava/lang/String;I)V", "")]
protected Enum (string name, int ordinal);
[<Android.Runtime.Register(".ctor", "(Ljava/lang/String;I)V", "")>]
new Java.Lang.Enum : string * int -> Java.Lang.Enum

Parameters

name
String
  • The name of this enum constant, which is the identifier used to declare it.
ordinal
Int32
  • The ordinal of this enumeration constant (its position in the enum declaration, where the initial constant is assigned an ordinal of zero).
Attributes

Remarks

Sole constructor. Programmers cannot invoke this constructor. It is for use by code emitted by the compiler in response to enum class declarations.

Java documentation for java.lang.Enum.Enum(java.lang.String, int).

Portions of this page are modifications based on work created and shared by the Android Open Source Project and used according to terms described in the Creative Commons 2.5 Attribution License.

Applies to