MCPcopy Create free account
hub / github.com/codenameone/CodenameOne / lastIndexOf

Method lastIndexOf

vm/JavaAPI/src/java/lang/String.java:468–475  ·  view source on GitHub ↗

Returns the index within this string of the last occurrence of the specified character. That is, the index returned is the largest value such that: this.charAt( ) == ch is true. The String is searched backwards starting at the last character.

(int ch)

Source from the content-addressed store, hash-verified

466 * ) == ch is true. The String is searched backwards starting at the last character.
467 */
468 public int lastIndexOf(int ch){
469 for(int iter = count + offset - 1 ; iter >= offset ; iter--) {
470 if(value[iter] == ch) {
471 return iter - offset;
472 }
473 }
474 return -1;
475 }
476
477 /**
478 * Returns the index within this string of the last occurrence of the specified character, searching backward starting at the specified index. That is, the index returned is the largest value

Callers 15

childToDisplayLabelMethod · 0.95
formatTimeMethod · 0.95
getParentMethod · 0.95
initImplMethod · 0.95
installTarMethod · 0.95
toStringMethod · 0.95
parseMethod · 0.95
paramStringMethod · 0.95
getComponentsNamesMethod · 0.95
toStringMethod · 0.95
convertURLMethod · 0.95

Calls 3

lengthMethod · 0.95
lengthMethod · 0.65
toCharArrayMethod · 0.45