ドキュメント

Unity Engine

Download Unity

Unity Engine

CallStaticObjectMethod

Invokes the specified \<tt\>methodID\</tt\> static method on a Java object, optionally passing in an array of arguments (\<tt\>args\</tt\>).
読み終わるまでの所要時間 1 分最終更新 1ヶ月前

Definition

  • Type: Method
  • Namespace: UnityEngine
  • Assembly: UnityEngine.AndroidJNIModule

CallStaticObjectMethod(IntPtr, IntPtr, jvalue[])

Invokes the specified \<tt\>methodID\</tt\> static method on a Java object, optionally passing in an array of arguments (\<tt\>args\</tt\>).
public static nint CallStaticObjectMethod(nint clazz, nint methodID, jvalue[] args)

Parameters

clazz

The Java class on which to call the static method.

methodID

The ID of the method to call.

args

jvalue[]
An array of arguments to pass to the method.

Returns

Type

Description

IntPtrA local reference to the Java object returned by the method.

Remarks

This method returns a reference to a \<tt\>java.lang.Object\</tt\>, or a subclass thereof.

CallStaticObjectMethod(IntPtr, IntPtr, Span<jvalue>)

Invokes the specified
methodID
static method on a Java object, optionally passing in an array of arguments (
args
).
public static nint CallStaticObjectMethod(nint clazz, nint methodID, Span<jvalue> args)

Parameters

clazz

The Java class on which to call the static method.

methodID

The ID of the method to call.

An array of arguments to pass to the method.

Returns

Type

Description

IntPtrA local reference to the Java object returned by the method.

Remarks

This method returns a reference to a
java.lang.Object
, or a subclass thereof.