public class JavaScriptMapWriterBehavior
extends org.apache.wicket.behavior.AbstractBehavior
AbstractBehavior
to write JavaScript variables.
It takes a Map and writes it to JavaScript. The Map key's are variables and the values
are the values of the variable. The attributes are loaded only after the Page is fully loaded.
(@ IHeaderResponse.renderOnLoadJavascript(String)
)
Constructor and Description |
---|
JavaScriptMapWriterBehavior() |
JavaScriptMapWriterBehavior(Map<String,Object> properties) |
JavaScriptMapWriterBehavior(Map<String,Object> properties,
String fileName) |
Modifier and Type | Method and Description |
---|---|
String |
getFileName()
Template JS file name
|
Map<String,Object> |
getProperties() |
void |
renderHead(org.apache.wicket.markup.html.IHeaderResponse response) |
void |
setFileName(String fileName)
Template JS file name
|
void |
setProperties(Map<String,Object> properties) |
public void renderHead(org.apache.wicket.markup.html.IHeaderResponse response)
renderHead
in interface org.apache.wicket.markup.html.IHeaderContributor
renderHead
in class org.apache.wicket.behavior.AbstractBehavior
public String getFileName()
public void setFileName(String fileName)
fileName
- as StringCopyright © 2018. All rights reserved.