Skip to content

Commit 1fe822c

Browse files
authored
WW-5529 Drops unused misleading setter setMaxLength in favour of setMaxlength (#1221) (#1222)
1 parent ef90b3b commit 1fe822c

File tree

1 file changed

+8
-14
lines changed

1 file changed

+8
-14
lines changed

core/src/main/java/org/apache/struts2/components/TextField.java

Lines changed: 8 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -50,17 +50,16 @@
5050
* </pre>
5151
*/
5252
@StrutsTag(
53-
name="textfield",
54-
tldTagClass="org.apache.struts2.views.jsp.ui.TextFieldTag",
55-
description="Render an HTML input field of type text",
56-
allowDynamicAttributes=true)
53+
name = "textfield",
54+
tldTagClass = "org.apache.struts2.views.jsp.ui.TextFieldTag",
55+
description = "Render an HTML input field of type text",
56+
allowDynamicAttributes = true)
5757
public class TextField extends UIBean {
5858
/**
5959
* The name of the default template for the TextFieldTag
6060
*/
6161
final public static String TEMPLATE = "text";
6262

63-
6463
protected String maxlength;
6564
protected String readonly;
6665
protected String size;
@@ -95,27 +94,22 @@ protected void evaluateExtraParams() {
9594

9695
}
9796

98-
@StrutsTagAttribute(description="HTML maxlength attribute", type="Integer")
97+
@StrutsTagAttribute(description = "HTML maxlength attribute", type = "Integer")
9998
public void setMaxlength(String maxlength) {
10099
this.maxlength = maxlength;
101100
}
102101

103-
@StrutsTagAttribute(description="Deprecated. Use maxlength instead.", type="Integer")
104-
public void setMaxLength(String maxlength) {
105-
this.maxlength = maxlength;
106-
}
107-
108-
@StrutsTagAttribute(description="Whether the input is readonly", type="Boolean", defaultValue="false")
102+
@StrutsTagAttribute(description = "Whether the input is readonly", type = "Boolean", defaultValue = "false")
109103
public void setReadonly(String readonly) {
110104
this.readonly = readonly;
111105
}
112106

113-
@StrutsTagAttribute(description="HTML size attribute", type="Integer")
107+
@StrutsTagAttribute(description = "HTML size attribute", type = "Integer")
114108
public void setSize(String size) {
115109
this.size = size;
116110
}
117111

118-
@StrutsTagAttribute(description="Specifies the html5 type element to display. e.g. text, email, url", defaultValue="text")
112+
@StrutsTagAttribute(description = "Specifies the html5 type element to display. e.g. text, email, url", defaultValue = "text")
119113
public void setType(String type) {
120114
this.type = type;
121115
}

0 commit comments

Comments
 (0)