Language

JniType.TryParse(String, JniType) Method

Definition

Attempts to resolve a Java class and wrap its class reference.

public static bool TryParse(string name, out Java.Interop.JniType? type);
static member TryParse : string * JniType -> bool

Parameters

name
String

The class name to resolve.

type
JniType

The new global-reference wrapper on success, or null when the class lookup fails.

Returns

true when class lookup succeeds and the wrapper is created; false when lookup finds no class.

Remarks

A failed class lookup returns false. Invalid arguments and reference-creation failures can still throw.

Applies to