T - type of inherrit context object.public abstract class Context<T extends Context<?>> extends Component
| Constructor and Description |
|---|
Context(ISkinConfig config,
ContextType type)
Default constructor.
|
| Modifier and Type | Method and Description |
|---|---|
static Context<?> |
buildContext(ISkinConfig config)
Build a context depending of current type of page.
|
Footer |
getFooter() |
Navbar |
getNavbar() |
ScrollTop |
getScrollTop() |
String |
getType() |
protected void |
initialize(ISkinConfig config)
Allows to initialize the context.
|
protected String |
onPreRender(ISkinConfig skinConfig,
String bodyContent)
generic pre-rendering method executed on all components of context.
|
String |
preRender(ISkinConfig skinConfig)
Allows to execute action before rendering of component.
|
String |
renderSnippets(ISkinConfig skinConfig,
String bodyContent) |
protected T |
self() |
String |
toString() |
protected T |
withType(ContextType type)
Sets the type of context.
|
addChildren, addCssOptions, getBodyContent, getCssClass, getCssOptions, getHtmlTool, setCssClasspublic Context(@Nonnull ISkinConfig config, @Nonnull ContextType type)
config - a config (can not be null).type - the type of context (can not be null).@Nonnull public static Context<?> buildContext(@Nonnull ISkinConfig config)
config - a config (can not be null).Context depending of current page.protected void initialize(@Nonnull ISkinConfig config)
config - a config (can not be null).public String preRender(@Nonnull ISkinConfig skinConfig)
skinConfig - a config (can not be null).String representing the transformed body content.protected String onPreRender(@Nonnull ISkinConfig skinConfig, @Nonnull String bodyContent)
ComponentonPreRender in class ComponentskinConfig - the current skin config.bodyContent - the current body content.String representing the transformed body content on pre-rendering.public String renderSnippets(ISkinConfig skinConfig, String bodyContent) throws IOException
IOExceptionprotected T withType(ContextType type)
type - the of context.public String getType()
protected T self()
Copyright © 2012–2023 Friederich Christophe. All rights reserved.