Class AutoLabelTextResolver

  • All Implemented Interfaces:
    Serializable, IComponentResolver, IClusterable

    public class AutoLabelTextResolver
    extends Object
    implements IComponentResolver
    Resolver that provides the <wicket:label> tag, which will output a FormComponent's label without requiring a manual extra component such as Label or FormComponentLabel. <wicket:label> can be used
    • together with <label wicket:for="...">:
       
       <label wicket:for="myFormComponent">some other markup, optionally<wicket:label/></label>
       
       
    • standalone, with a for attribute:
       
       <wicket:label for="myFormComponent"/>
       
       

    It also supports both input and output:

    • If the FormComponent has a label model, the <wicket:label> tag will be replaced by the contents of that label.
    • If the FormComponent's label model is null, it can be picked up from <wicket:label>:
      • <wicket:label> can contain some raw markup, like this:
         
         <wicket:label>I will become the component's label!</wicket:label>
         
         
      • Or it can be a message pulled from resources, similar to <wicket:message/>:
         
         <wicket:label key="messagekey"/>
         
         
    Author:
    Carl-Eric Menzel, igor
    See Also:
    Serialized Form