You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: src/changes/changes.xml
+1Lines changed: 1 addition & 0 deletions
Original file line number
Diff line number
Diff line change
@@ -55,6 +55,7 @@ The <action> type attribute can be add,update,fix,remove.
55
55
<actiontype="fix"dev="ggregory"due-to="Scott Parish">[javadoc] Strings::equalsAny: CI doc string should show it's insensitive #1416.</action>
56
56
<actiontype="fix"dev="ggregory"due-to="Gary Gregory">Reduce spurious failures in org.apache.commons.lang3.ArrayUtilsTest methods that test ArrayUtils.shuffle() methods.</action>
Copy file name to clipboardExpand all lines: src/main/java/org/apache/commons/lang3/CharSequenceUtils.java
+43-46Lines changed: 43 additions & 46 deletions
Original file line number
Diff line number
Diff line change
@@ -72,43 +72,38 @@ static int indexOf(final CharSequence cs, final CharSequence searchChar, final i
72
72
}
73
73
74
74
/**
75
-
* Returns the index within {@code cs} of the first occurrence of the
76
-
* specified character, starting the search at the specified index.
75
+
* Returns the index within {@code cs} of the first occurrence of the specified character, starting the search at the specified index.
77
76
* <p>
78
-
* If a character with value {@code searchChar} occurs in the
79
-
* character sequence represented by the {@code cs}
80
-
* object at an index no smaller than {@code start}, then
81
-
* the index of the first such occurrence is returned. For values
82
-
* of {@code searchChar} in the range from 0 to 0xFFFF (inclusive),
83
-
* this is the smallest value <em>k</em> such that:
77
+
* If a character with value {@code searchChar} occurs in the character sequence represented by the {@code cs} object at an index no smaller than
78
+
* {@code start}, then the index of the first such occurrence is returned. For values of {@code searchChar} in the range from 0 to 0xFFFF (inclusive), this
* is true. In either case, if no such character occurs inm {@code cs}
95
-
* at or after position {@code start}, then
96
-
* {@code -1} is returned.
93
+
* is true. In either case, if no such character occurs inm {@code cs} at or after position {@code start}, then {@code -1} is returned.
97
94
* </p>
98
95
* <p>
99
-
* There is no restriction on the value of {@code start}. If it
100
-
* is negative, it has the same effect as if it were zero: the entire
101
-
* {@link CharSequence} may be searched. If it is greater than
102
-
* the length of {@code cs}, it has the same effect as if it were
103
-
* equal to the length of {@code cs}: {@code -1} is returned.
96
+
* There is no restriction on the value of {@code start}. If it is negative, it has the same effect as if it were zero: the entire {@link CharSequence} may
97
+
* be searched. If it is greater than the length of {@code cs}, it has the same effect as if it were equal to the length of {@code cs}: {@code -1} is
98
+
* returned.
104
99
* </p>
105
-
* <p>All indices are specified in {@code char} values
106
-
* (Unicode code units).
100
+
* <p>
101
+
* All indices are specified in {@code char} values (Unicode code units).
107
102
* </p>
108
103
*
109
-
* @param cs the {@link CharSequence} to be processed, not null
110
-
* @param searchChar the char to be searched for
111
-
* @param start the start index, negative starts at the string start
104
+
* @param cs the {@link CharSequence} to be processed, not null
105
+
* @param searchChar the char to be searched for
106
+
* @param start the start index, negative starts at the string start
112
107
* @return the index where the search char was found, -1 if not found
113
108
* @since 3.6 updated to behave more like {@link String}
114
109
*/
@@ -218,31 +213,33 @@ static int lastIndexOf(final CharSequence cs, final CharSequence searchChar, int
218
213
}
219
214
220
215
/**
221
-
* Returns the index within {@code cs} of the last occurrence of
222
-
* the specified character, searching backward starting at the
223
-
* specified index. For values of {@code searchChar} in the range
224
-
* from 0 to 0xFFFF (inclusive), the index returned is the largest
225
-
* value <em>k</em> such that:
226
-
* <blockquote><pre>
216
+
* Returns the index within {@code cs} of the last occurrence of the specified character, searching backward starting at the specified index. For values of
217
+
* {@code searchChar} in the range from 0 to 0xFFFF (inclusive), the index returned is the largest value <em>k</em> such that:
0 commit comments