File tree 6 files changed +55
-1
lines changed
src/main/java/org/apache/commons/beanutils2/converters
6 files changed +55
-1
lines changed Original file line number Diff line number Diff line change @@ -60,6 +60,9 @@ public ColorConverter() {
60
60
}
61
61
62
62
/**
63
+ * Constructs a {@link org.apache.commons.beanutils2.Converter} that will return
64
+ * the specified default value if a conversion error occurs.
65
+ *
63
66
* @param defaultValue The default value to be returned
64
67
* if the value to be converted is missing or an error
65
68
* occurs converting the value.
@@ -68,14 +71,20 @@ public ColorConverter(final Object defaultValue) {
68
71
super (defaultValue );
69
72
}
70
73
74
+ /**
75
+ * Gets the default type this {@code Converter} handles.
76
+ *
77
+ * @return The default type this {@code Converter} handles.
78
+ * @since 2.0.0
79
+ */
71
80
@ Override
72
81
protected Class <?> getDefaultType () {
73
82
return Color .class ;
74
83
}
75
84
76
85
/**
77
86
* <p>
78
- * Convert the configuration value to a Java {@link Color} object,
87
+ * Converts the configuration value to a Java {@link Color} object,
79
88
* by reading the hexadecimal {@link String} and converting each component.
80
89
* </p>
81
90
*
Original file line number Diff line number Diff line change @@ -53,6 +53,9 @@ public DimensionConverter() {
53
53
}
54
54
55
55
/**
56
+ * Constructs a {@link org.apache.commons.beanutils2.Converter} that will return
57
+ * the specified default value if a conversion error occurs.
58
+ *
56
59
* @param defaultValue The default value to be returned
57
60
* if the value to be converted is missing or an error
58
61
* occurs converting the value.
@@ -61,6 +64,12 @@ public DimensionConverter(final Object defaultValue) {
61
64
super (defaultValue );
62
65
}
63
66
67
+ /**
68
+ * Gets the default type this {@code Converter} handles.
69
+ *
70
+ * @return The default type this {@code Converter} handles.
71
+ * @since 2.0.0
72
+ */
64
73
@ Override
65
74
protected Class <?> getDefaultType () {
66
75
return Dimension .class ;
Original file line number Diff line number Diff line change @@ -39,6 +39,9 @@ public InetAddressConverter() {
39
39
}
40
40
41
41
/**
42
+ * Constructs a {@link org.apache.commons.beanutils2.Converter} that will return
43
+ * the specified default value if a conversion error occurs.
44
+ *
42
45
* @param defaultValue The default value to be returned
43
46
* if the value to be converted is missing or an error
44
47
* occurs converting the value.
@@ -47,6 +50,12 @@ public InetAddressConverter(final Object defaultValue) {
47
50
super (defaultValue );
48
51
}
49
52
53
+ /**
54
+ * Gets the default type this {@code Converter} handles.
55
+ *
56
+ * @return The default type this {@code Converter} handles.
57
+ * @since 2.0.0
58
+ */
50
59
@ Override
51
60
protected Class <?> getDefaultType () {
52
61
return InetAddress .class ;
Original file line number Diff line number Diff line change @@ -37,6 +37,9 @@ public LocaleConverter() {
37
37
}
38
38
39
39
/**
40
+ * Constructs a {@link org.apache.commons.beanutils2.Converter} that will return
41
+ * the specified default value if a conversion error occurs.
42
+ *
40
43
* @param defaultValue The default value to be returned
41
44
* if the value to be converted is missing or an error
42
45
* occurs converting the value.
@@ -45,6 +48,12 @@ public LocaleConverter(final Object defaultValue) {
45
48
super (defaultValue );
46
49
}
47
50
51
+ /**
52
+ * Gets the default type this {@code Converter} handles.
53
+ *
54
+ * @return The default type this {@code Converter} handles.
55
+ * @since 2.0.0
56
+ */
48
57
@ Override
49
58
protected Class <?> getDefaultType () {
50
59
return Locale .class ;
Original file line number Diff line number Diff line change @@ -37,6 +37,9 @@ public PatternConverter() {
37
37
}
38
38
39
39
/**
40
+ * Constructs a {@link org.apache.commons.beanutils2.Converter} that will return
41
+ * the specified default value if a conversion error occurs.
42
+ *
40
43
* @param defaultValue The default value to be returned
41
44
* if the value to be converted is missing or an error
42
45
* occurs converting the value.
@@ -45,6 +48,12 @@ public PatternConverter(final Object defaultValue) {
45
48
super (defaultValue );
46
49
}
47
50
51
+ /**
52
+ * Gets the default type this {@code Converter} handles.
53
+ *
54
+ * @return The default type this {@code Converter} handles.
55
+ * @since 2.0.0
56
+ */
48
57
@ Override
49
58
protected Class <?> getDefaultType () {
50
59
return Pattern .class ;
Original file line number Diff line number Diff line change @@ -39,6 +39,9 @@ public PointConverter() {
39
39
}
40
40
41
41
/**
42
+ * Constructs a {@link org.apache.commons.beanutils2.Converter} that will return
43
+ * the specified default value if a conversion error occurs.
44
+ *
42
45
* @param defaultValue The default value to be returned
43
46
* if the value to be converted is missing or an error
44
47
* occurs converting the value.
@@ -47,6 +50,12 @@ public PointConverter(final Object defaultValue) {
47
50
super (defaultValue );
48
51
}
49
52
53
+ /**
54
+ * Gets the default type this {@code Converter} handles.
55
+ *
56
+ * @return The default type this {@code Converter} handles.
57
+ * @since 2.0.0
58
+ */
50
59
@ Override
51
60
protected Class <?> getDefaultType () {
52
61
return Point .class ;
You can’t perform that action at this time.
0 commit comments