org.apache.wicket.markup.resolver
Class FragmentResolver

java.lang.Object
  extended by org.apache.wicket.markup.resolver.FragmentResolver
All Implemented Interfaces:
Serializable, IClusterable, IComponentResolver

public class FragmentResolver
extends Object
implements IComponentResolver

Usually you either have a markup file or a xml tag with wicket:id="myComponent" to associate markup with a component. However in some rare cases, especially when working with small panels it is a bit awkward to maintain tiny pieces of markup in plenty of panel markup files. Use cases are for example list views where list items are different depending on a state.

Inline panels provide a means to maintain the panels tiny piece of markup in the parents markup file. During the render process, when Wicket iterates over the markup file, the markup fragment must be ignored. It is only indirectly referenced by component.

Author:
Juergen Donnerstag
See Also:
Serialized Form

Constructor Summary
FragmentResolver()
           
 
Method Summary
 boolean resolve(MarkupContainer container, MarkupStream markupStream, ComponentTag tag)
          Try to resolve the tag, then create a component, add it to the container and render it.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

FragmentResolver

public FragmentResolver()
Method Detail

resolve

public boolean resolve(MarkupContainer container,
                       MarkupStream markupStream,
                       ComponentTag tag)
Description copied from interface: IComponentResolver
Try to resolve the tag, then create a component, add it to the container and render it.

Specified by:
resolve in interface IComponentResolver
Parameters:
container - The container parsing its markup
markupStream - The current markupStream
tag - The current component tag while parsing the markup
Returns:
true, if componentId was handle by the resolver. False, otherwise
See Also:
IComponentResolver.resolve(MarkupContainer, MarkupStream, ComponentTag)


Copyright © 2004-2011 Apache Software Foundation. All Rights Reserved.