Class SizeTagModifier
java.lang.Object
org.apache.wicket.bean.validation.SizeTagModifier
- All Implemented Interfaces:
ITagModifier<jakarta.validation.constraints.Size>
public class SizeTagModifier
extends Object
implements ITagModifier<jakarta.validation.constraints.Size>
A tag modifier that adds the
maxlength
and minlength
attributes to the input
and textarea
tag with the max/min value from the Size
constraint annotation.- Author:
- igor
-
Field Summary
Fields inherited from interface org.apache.wicket.bean.validation.ITagModifier
NO_OP
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionprotected boolean
hasLengthAttribute
(String tagName) void
modify
(FormComponent<?> component, ComponentTag tag, jakarta.validation.constraints.Size annotation) Modify the tag
-
Constructor Details
-
SizeTagModifier
public SizeTagModifier()
-
-
Method Details
-
modify
public void modify(FormComponent<?> component, ComponentTag tag, jakarta.validation.constraints.Size annotation) Description copied from interface:ITagModifier
Modify the tag- Specified by:
modify
in interfaceITagModifier<jakarta.validation.constraints.Size>
- Parameters:
component
- component the tag belongs totag
- markup tag to be modifiedannotation
- constraint annotation
-
hasLengthAttribute
-