public final class RelativePathPrefixHandler extends AbstractMarkupFilter implements IComponentResolver
Modifier and Type | Field and Description |
---|---|
static Behavior |
RELATIVE_PATH_BEHAVIOR
Behavior that adds a prefix to src, href and background attributes to make them
context-relative
|
static String |
WICKET_RELATIVE_PATH_PREFIX_CONTAINER_ID
The id automatically assigned to tags without an id which we need to prepend a relative path
to.
|
REQUEST_COUNTER_KEY
Constructor and Description |
---|
RelativePathPrefixHandler()
Constructor for the IComponentResolver role.
|
RelativePathPrefixHandler(MarkupResourceStream markup)
Constructor for the IMarkupFilter role
|
Modifier and Type | Method and Description |
---|---|
protected MarkupElement |
onComponentTag(ComponentTag tag)
Invoked when a ComponentTag was found.
|
void |
postProcess(Markup markup)
Called after all filters have been processed.
|
Component |
resolve(MarkupContainer container,
MarkupStream markupStream,
ComponentTag tag)
Try to resolve a component.
|
getMarkupResourceStream, getNextFilter, getRequestUniqueId, getWicketNamespace, getWicketNamespace, nextElement, onSpecialTag, setNextFilter
public static final String WICKET_RELATIVE_PATH_PREFIX_CONTAINER_ID
public static final Behavior RELATIVE_PATH_BEHAVIOR
public RelativePathPrefixHandler()
public RelativePathPrefixHandler(MarkupResourceStream markup)
markup
- The markup created by reading the markup fileprotected final MarkupElement onComponentTag(ComponentTag tag) throws ParseException
AbstractMarkupFilter
By default this method is also called for WicketTags.
onComponentTag
in class AbstractMarkupFilter
ParseException
public Component resolve(MarkupContainer container, MarkupStream markupStream, ComponentTag tag)
IComponentResolver
resolve
in interface IComponentResolver
container
- The container parsing its markupmarkupStream
- The current markupStreamtag
- The current component tag while parsing the markupnull
if not foundpublic void postProcess(Markup markup)
IMarkupFilter
postProcess
in interface IMarkupFilter
postProcess
in class AbstractMarkupFilter
Copyright © 2006–2019 Apache Software Foundation. All rights reserved.