JniEnvironment.Object.NewObject Method
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Overloads
| Name | Description |
|---|---|
| NewObject(JniObjectReference, JniMethodInfo) |
Allocates an object and invokes its zero-argument constructor. |
| NewObject(JniObjectReference, JniMethodInfo, JniArgumentValue*) |
Allocates an object and invokes a constructor with the supplied JNI arguments. |
NewObject(JniObjectReference, JniMethodInfo)
Allocates an object and invokes its zero-argument constructor.
public static Java.Interop.JniObjectReference NewObject(Java.Interop.JniObjectReference type, Java.Interop.JniMethodInfo method);
static member NewObject : Java.Interop.JniObjectReference * Java.Interop.JniMethodInfo -> Java.Interop.JniObjectReference
Parameters
- type
- JniObjectReference
A valid reference to the Java class.
- method
- JniMethodInfo
The zero-argument constructor identifier.
Returns
The local object reference returned by JNI.
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
NewObject(JniObjectReference, JniMethodInfo, JniArgumentValue*)
Allocates an object and invokes a constructor with the supplied JNI arguments.
public static Java.Interop.JniObjectReference NewObject(Java.Interop.JniObjectReference type, Java.Interop.JniMethodInfo method, Java.Interop.JniArgumentValue* args);
static member NewObject : Java.Interop.JniObjectReference * Java.Interop.JniMethodInfo * nativeptr<Java.Interop.JniArgumentValue> -> Java.Interop.JniObjectReference
Parameters
- type
- JniObjectReference
A valid reference to the Java class.
- method
- JniMethodInfo
The constructor identifier for that class.
- args
- JniArgumentValue*
Argument values in the constructor descriptor's order.
Returns
The local object reference returned by JNI.
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.