# NewObjectA(nint, nint, jvalue*)

> Constructs a new Java object. The method ID indicates which constructor method to invoke. This ID must be obtained by calling GetMethodID() with \<init\> as the method name and void (V) as the return type.

## Definition

* **Type:** Method
* **Namespace:** [UnityEngine](/engine/7000.0/script-reference/unityengine.md)
* **Assembly:** UnityEngine.AndroidJNIModule

## NewObjectA(IntPtr, IntPtr, jvalue\*)

```csharp
public static nint NewObjectA(nint clazz, nint methodID, jvalue* args)
```

### Parameters

**** (\[IntPtr]\(https\://learn.microsoft.com/dotnet/api/system.intptr)): The Java class to instantiate.**** (\[IntPtr]\(https\://learn.microsoft.com/dotnet/api/system.intptr)): The ID of the constructor to invoke.**** (jvalue\*): An array of arguments to pass to the constructor.

### Returns

| Type                                                           | Description                                        |
| -------------------------------------------------------------- | -------------------------------------------------- |
| [IntPtr](https://learn.microsoft.com/dotnet/api/system.intptr) | A local reference to the newly constructed object. |

### Remarks

Additional Resources: [Java Native Interface Specification (Oracle)](http://download.oracle.com/javase/1.5.0/docs/guide/jni/spec/jniTOC.html)
