Version: 5.3 (switch to 5.4b)
IdiomaEnglish
  • C#
  • JS

Idioma de script

Selecciona tu lenguaje de programación favorito. Todos los fragmentos de código serán mostrados en este lenguaje.

AndroidJNIHelper.GetMethodID

Sugiere un cambio

¡Éxito!

Gracias por ayudarnos a mejorar la calidad de la documentación de Unity. A pesar de que no podemos aceptar todas las sugerencias, leemos cada cambio propuesto por nuestros usuarios y actualizaremos los que sean aplicables.

Cerrar

No se puedo enviar

Por alguna razón su cambio sugerido no pudo ser enviado. Por favor <a>intente nuevamente</a> en unos minutos. Gracias por tomarse un tiempo para ayudarnos a mejorar la calidad de la documentación de Unity.

Cerrar

Cancelar

Cambiar al Manual
public static function GetMethodID(javaClass: IntPtr, methodName: string, signature: string = "", isStatic: bool = false): IntPtr;
public static IntPtr GetMethodID(IntPtr javaClass, string methodName, string signature = "", bool isStatic = false);
public static function GetMethodID(javaClass: IntPtr, methodName: string, signature: string = "", isStatic: bool = false): IntPtr;
public static IntPtr GetMethodID(IntPtr javaClass, string methodName, string signature = "", bool isStatic = false);
public static function GetMethodID(javaClass: IntPtr, methodName: string, signature: string = "", isStatic: bool = false): IntPtr;
public static IntPtr GetMethodID(IntPtr javaClass, string methodName, string signature = "", bool isStatic = false);

Parámetros

javaClass Raw JNI Java class object (obtained by calling AndroidJNI.FindClass).
methodName Name of the method as declared in Java.
signature Method signature (e.g. obtained by calling AndroidJNIHelper.GetSignature).
isStatic Set to true for static methods; false for instance (nonstatic) methods.

Descripción

Scans a particular Java class for a method matching a name and a signature.

The signature comparison is done to allow sub-/base-classes of a class types. If no signature is provided the first method with the correct name will be returned.

See Also: AndroidJNIHelper.GetSignature, AndroidJNIHelper.GetConstructorID, AndroidJNIHelper.GetFieldID.


public static function GetMethodID(jclass: IntPtr, methodName: string, args: object[], isStatic: bool): IntPtr;
public static IntPtr GetMethodID(IntPtr jclass, string methodName, object[] args, bool isStatic);

Parámetros

javaClass Raw JNI Java class object (obtained by calling AndroidJNI.FindClass).
methodName Name of the method as declared in Java.
args Array with parameters to be passed to the method when invoked.
isStatic Set to true for static methods; false for instance (nonstatic) methods.

Descripción

Get a JNI method ID based on calling arguments.

Generic parameter represents the method return type, and the regular method assumes 'void' return type. Scans a particular Java class for a method matching a signature based on passed arguments. The signature comparison is done to allow for sub-/base-classes of the class types.


public static function GetMethodID(jclass: IntPtr, methodName: string, args: object[], isStatic: bool): IntPtr;
public static IntPtr GetMethodID(IntPtr jclass, string methodName, object[] args, bool isStatic);

Parámetros

javaClass Raw JNI Java class object (obtained by calling AndroidJNI.FindClass).
methodName Name of the method as declared in Java.
args Array with parameters to be passed to the method when invoked.
isStatic Set to true for static methods; false for instance (nonstatic) methods.

Descripción

Get a JNI method ID based on calling arguments.

Generic parameter represents the method return type, and the regular method assumes 'void' return type. Scans a particular Java class for a method matching a signature based on passed arguments. The signature comparison is done to allow for sub-/base-classes of the class types.