public abstract class JavascriptObject extends Object implements IJavascriptObject
Modifier and Type | Field and Description |
---|---|
static long |
counter
Counter for generating instance identifiers.
|
static String |
JS_GLOBAL
Global variable for holding all of our Javascript objects and data.
|
static Map<Object,String> |
objectIds
Map for starting object Ids.
|
Constructor and Description |
---|
JavascriptObject()
Creates a new instance.
|
Modifier and Type | Method and Description |
---|---|
protected String |
escapeQuoteJs(String text)
Escapes single quotation marks in the provided String.
|
String |
getJsId()
Returns a String with the unique ID used to identify this object.
|
String |
getJsIdWithSuffix(String suffix)
Returns a String with the unique ID used to identify this object with the suffix appended.
|
abstract String |
getJsType()
Returns a String with the type of Javascript object that this object represents.
|
abstract String |
renderJs()
Returns a String with containing the rendered Javascript code for this object.
|
public static final String JS_GLOBAL
public static long counter
public abstract String getJsType()
getJsType
in interface IJavascriptObject
public String getJsId()
getJsId
in interface IJavascriptObject
public String getJsIdWithSuffix(String suffix)
public abstract String renderJs()
renderJs
in interface IJavascriptObject
Copyright © 2015. All rights reserved.