
public final class JsValueGlue extends Object
| Modifier and Type | Field and Description |
|---|---|
static String |
HOSTED_MODE_REFERENCE |
static String |
JSO_CLASS |
static String |
JSO_IMPL_CLASS |
| Modifier and Type | Method and Description |
|---|---|
static Object |
createJavaScriptObject(JsValue value,
CompilingClassLoader classLoader)
Create a JavaScriptObject instance referring to this JavaScript object.
|
static <T> T |
get(JsValue value,
CompilingClassLoader cl,
Class<T> type,
String msgPrefix)
Return an object containing the value JavaScript object as a specified
type.
|
static void |
set(JsValue value,
CompilingClassLoader cl,
Class<?> type,
Object obj)
Set the underlying value.
|
public static final String HOSTED_MODE_REFERENCE
public static final String JSO_CLASS
public static final String JSO_IMPL_CLASS
public static Object createJavaScriptObject(JsValue value, CompilingClassLoader classLoader)
classLoader - the classLoader to create frompublic static <T> T get(JsValue value, CompilingClassLoader cl, Class<T> type, String msgPrefix)
value - the JavaScript valuetype - expected type of the returned objectmsgPrefix - a prefix for error/warning messagesHostedModeException - if the JavaScript
object is not assignable to the supplied type.public static void set(JsValue value, CompilingClassLoader cl, Class<?> type, Object obj)
value - JsValue to settype - static type of the objectobj - the object to store in the JS valueCopyright © 2018. All rights reserved.