public class VelocityJavaScriptContributor extends VelocityContributor
IHeaderResponse.render(org.apache.wicket.markup.head.HeaderItem)
Constructor and Description |
---|
VelocityJavaScriptContributor(Class<?> clazz,
String templatePath,
IModel<? extends Map<?,?>> model,
String id)
Use this constructor if you have configured Velocity to use a ClasspathResourceLoader.
|
VelocityJavaScriptContributor(String templatePath,
IModel<? extends Map<?,?>> model,
String id)
Use this constructor when Velocity is configured with the
FileResourceLoader . |
Modifier and Type | Method and Description |
---|---|
void |
renderHead(Component component,
IHeaderResponse response)
Render to the web response whatever the component wants to contribute to the head section.
|
detach, escapeHtml, evaluate, getEncoding, setEncoding
afterRender, beforeRender, bind, canCallListenerInterface, getStatelessHint, isEnabled, isTemporary, onComponentTag, onConfigure, onEvent, onException, onRemove, unbind
public VelocityJavaScriptContributor(Class<?> clazz, String templatePath, IModel<? extends Map<?,?>> model, String id)
clazz
- templatePath
- model
- id
- public VelocityJavaScriptContributor(String templatePath, IModel<? extends Map<?,?>> model, String id)
FileResourceLoader
.
templatePath with then be relative to the loader path configured in velocity.propertiestemplatePath
- model
- id
- public void renderHead(Component component, IHeaderResponse response)
renderHead
in interface IComponentAwareHeaderContributor
renderHead
in class VelocityContributor
component
- component which is contributing to the response. This parameter is here to give
the component as the context for component-awares implementing this interfaceresponse
- Response objectCopyright © 2006–2021 Apache Software Foundation. All rights reserved.