public final class UnsafeCast extends Object
| Modifier and Type | Method and Description |
|---|---|
static <T extends JsiiSerializable> |
unsafeCast(JsiiObject value,
Class<T> target)
Unsafely obtains a view on a given value as an instance of an interface annotated with the
Jsii.Proxy
annotation. |
public static <T extends JsiiSerializable> T unsafeCast(JsiiObject value, Class<T> target)
Jsii.Proxy
annotation.T - the return type of the cast.value - the value to be converted.target - the target type to obtain. This must be an interface with the Jsii.Proxy annotation.null if value is null.IllegalArgumentException - if the provided target is not a Jsii.Proxy annotated interface.Copyright © 2022 Amazon Web Services. All rights reserved.