
public class JavaToJavaScriptMapImpl extends Object implements JavaToJavaScriptMap
EMPTY| Constructor and Description |
|---|
JavaToJavaScriptMapImpl(List<JDeclaredType> types,
Map<HasName,JsName> names,
Map<JsStatement,JClassType> typeForStatement,
Map<JsStatement,JMethod> vtableInitForMethod) |
| Modifier and Type | Method and Description |
|---|---|
JsName |
nameForField(JField field)
Return the JavaScript name corresponding to a Java field.
|
JsName |
nameForMethod(JMethod method)
Return the JavaScript name corresponding to a Java method.
|
JsName |
nameForType(JClassType type)
Return the JavaScript name corresponding to a Java type.
|
JField |
nameToField(JsName name)
If
name is the name of a
var |
JMethod |
nameToMethod(JsName name)
If
name is the name of a function that corresponds to a Java
method, then return that method. |
JClassType |
nameToType(JsName name)
If
name is the name of a constructor function corresponding to
a Java type, then return that type. |
JClassType |
typeForStatement(JsStatement stat)
If
stat is used to set up the definition of some class, return
that class. |
JMethod |
vtableInitToMethod(JsStatement stat)
If
stat is used to set up a vtable entry for a method, then
return that method. |
public JavaToJavaScriptMapImpl(List<JDeclaredType> types, Map<HasName,JsName> names, Map<JsStatement,JClassType> typeForStatement, Map<JsStatement,JMethod> vtableInitForMethod)
public JsName nameForField(JField field)
JavaToJavaScriptMapnameForField in interface JavaToJavaScriptMappublic JsName nameForMethod(JMethod method)
JavaToJavaScriptMapnameForMethod in interface JavaToJavaScriptMappublic JsName nameForType(JClassType type)
JavaToJavaScriptMapnameForType in interface JavaToJavaScriptMappublic JField nameToField(JsName name)
JavaToJavaScriptMapname is the name of a
var that corresponds to a Java
static field, then return that field. Otherwise, return null.nameToField in interface JavaToJavaScriptMappublic JMethod nameToMethod(JsName name)
JavaToJavaScriptMapname is the name of a function that corresponds to a Java
method, then return that method. Otherwise, return null.nameToMethod in interface JavaToJavaScriptMappublic JClassType nameToType(JsName name)
JavaToJavaScriptMapname is the name of a constructor function corresponding to
a Java type, then return that type. Otherwise, return null.nameToType in interface JavaToJavaScriptMappublic JClassType typeForStatement(JsStatement stat)
JavaToJavaScriptMapstat is used to set up the definition of some class, return
that class. Otherwise, return null.typeForStatement in interface JavaToJavaScriptMappublic JMethod vtableInitToMethod(JsStatement stat)
JavaToJavaScriptMapstat is used to set up a vtable entry for a method, then
return that method. Otherwise return null.vtableInitToMethod in interface JavaToJavaScriptMapCopyright © 2018. All rights reserved.