public class BasicTilesContainer extends Object implements TilesContainer, AttributeEvaluatorFactoryAware
| Constructor and Description | 
|---|
| BasicTilesContainer() | 
| Modifier and Type | Method and Description | 
|---|---|
| void | endContext(Request request)Ends a context, where attribute values are stored independently of others. It must be called after a TilesContainer.startContext(Request)call. | 
| Object | evaluate(Attribute attribute,
        Request request)Evaluates the given attribute. | 
| ApplicationContext | getApplicationContext()Returns the Tiles application context used by this container. | 
| AttributeContext | getAttributeContext(Request request)Retrieve the attribute context of the current request. | 
| protected AttributeContext | getContext(Request tilesContext)Get attribute context from request. | 
| protected Deque<AttributeContext> | getContextStack(Request tilesContext)Returns the context stack. | 
| Definition | getDefinition(String definitionName,
             Request request)Returns a definition specifying its name. | 
| boolean | isValidDefinition(String definitionName,
                 Request request)Determine whether the definition exists. | 
| protected AttributeContext | popContext(Request tilesContext)Pops a context object out of the stack. | 
| void | prepare(String preparer,
       Request request)Executes a preparer. | 
| protected void | pushContext(AttributeContext context,
           Request tilesContext)Pushes a context object in the stack. | 
| void | render(Attribute attr,
      Request request)Render the given Attribute. | 
| void | render(Definition definition,
      Request request)Renders the specified definition. | 
| protected void | render(Request request,
      AttributeContext attributeContext)Renders the specified attribute context. | 
| void | render(String definitionName,
      Request request)Render the given tiles request. | 
| void | renderContext(Request request)Renders the current context, as it is. | 
| void | setApplicationContext(ApplicationContext context)Sets the Tiles application context to use. | 
| void | setAttributeEvaluatorFactory(AttributeEvaluatorFactory attributeEvaluatorFactory)Sets the attribute evaluator factory. | 
| void | setDefinitionsFactory(DefinitionsFactory definitionsFactory)Set the definitions factory. | 
| void | setPreparerFactory(PreparerFactory preparerFactory)Set the preparerInstance factory. | 
| void | setRendererFactory(RendererFactory rendererFactory)Sets the renderer instance factory. | 
| AttributeContext | startContext(Request request)Starts a new context, where attribute values are stored independently of others. When the use of the contexts is finished, call TilesContainer.endContext(Request) | 
public AttributeContext startContext(Request request)
TilesContainer.endContext(Request)startContext in interface TilesContainerrequest - The request.public void endContext(Request request)
TilesContainer.startContext(Request) call.endContext in interface TilesContainerrequest - The request.public void renderContext(Request request)
renderContext in interface TilesContainerrequest - The request.public ApplicationContext getApplicationContext()
getApplicationContext in interface TilesContainerpublic void setApplicationContext(ApplicationContext context)
context - The Tiles application context.public AttributeContext getAttributeContext(Request request)
getAttributeContext in interface TilesContainerrequest - The request.public void setDefinitionsFactory(DefinitionsFactory definitionsFactory)
definitionsFactory - the definitions factory for this instance.public void setPreparerFactory(PreparerFactory preparerFactory)
preparerFactory - the preparerInstance factory for this conainer.public void setRendererFactory(RendererFactory rendererFactory)
rendererFactory - the renderer instance factory for this container.public void setAttributeEvaluatorFactory(AttributeEvaluatorFactory attributeEvaluatorFactory)
setAttributeEvaluatorFactory in interface AttributeEvaluatorFactoryAwareattributeEvaluatorFactory - The attribute evaluator factory to use.public void prepare(String preparer, Request request)
prepare in interface TilesContainerpreparer - The name of the preparer to execute.request - The request.public void render(String definitionName, Request request)
render in interface TilesContainerdefinitionName - the current definition.request - The request.public void render(Definition definition, Request request)
render in interface TilesContainerdefinition - The definition to render.request - The request context.public void render(Attribute attr, Request request) throws IOException
render in interface TilesContainerattr - The attribute to render.request - The request.IOException - If something goes wrong during writing to the output.public Object evaluate(Attribute attribute, Request request)
evaluate in interface TilesContainerattribute - The attribute to evaluate.request - The request.public boolean isValidDefinition(String definitionName, Request request)
isValidDefinition in interface TilesContainerdefinitionName - the name of the definition.request - The request.public Definition getDefinition(String definitionName, Request request)
getDefinition in interface TilesContainerdefinitionName - The name of the definition to find.request - The request context.protected Deque<AttributeContext> getContextStack(Request tilesContext)
tilesContext - The Tiles context object to use.protected void pushContext(AttributeContext context, Request tilesContext)
context - The context to push.tilesContext - The Tiles context object to use.protected AttributeContext popContext(Request tilesContext)
tilesContext - The Tiles context object to use.protected AttributeContext getContext(Request tilesContext)
tilesContext - current Tiles application context.protected void render(Request request, AttributeContext attributeContext)
request - The request context.attributeContext - The context to render.InvalidTemplateException - If the template is not valid.CannotRenderException - If something goes wrong during rendering.Copyright © 2000–2025 Apache Software Foundation. All rights reserved.