Java Utililty Methods String Index Of

List of utility methods to do String Index Of

Description

The list of methods to do String Index Of are organized into topic(s).

Method

intgetPDFEncodingIndex(String key)
get PDF Encoding Index
return pdfencodings.indexOf(key);
voidgetReplaceIndexes(String input, int startIndex, Stack replaceStack)
get Replace Indexes
int idx = startIndex + 3;
Stack<Character> stack = new Stack<>();
while (idx < input.length()) {
    switch (input.charAt(idx)) {
    case ')':
        if (stack.isEmpty()) {
            idx = input.length();
        } else {
...
StringgetStructValue(String struct, int index)
get Struct Value
Vector vr = splitStruct(struct);
String value = (String) vr.elementAt(index);
value = replace(value, "[", "");
value = replace(value, "]", "");
return value;
ListgetTabIndexes(String text)
get Tab Indexes
List<Integer> tabIndexes = null;
if (text != null) {
    tabIndexes = new ArrayList<Integer>();
    for (int i = 0; i < text.length(); i++) {
        if (text.charAt(i) == '\t') {
            tabIndexes.add(Integer.valueOf(i));
return tabIndexes;
ListgetUserGroupsFromImpex(final String impexContent, final int uidIndex)
get User Groups From Impex
final List<String> list = new ArrayList<String>();
final String[] lines = impexContent.split("\n");
int index = 0;
while (!lines[index].trim().startsWith("INSERT_UPDATE UserGroup")) {
    index++;
while (++index < lines.length && lines[index].trim().startsWith(";")) {
    final String[] lineTockens = lines[index].split(";");
...
Integer[]indexOf(final String str, final String searchString)
Helper method for getId(String).
if (str == null || str.indexOf(searchString) < 0) {
    return null;
final List<Integer> list = new ArrayList<Integer>();
int pos = -1;
final int length = str.length();
for (int i = 0; i < 100; i++) {
    if (pos >= length - 1) {
...
intindexOfClosingBracket(String text, int openingBracket)
index Of Closing Bracket
int result = -1;
ArrayDeque<String> stack = new ArrayDeque<>();
for (int i = openingBracket; i < text.length(); i++) {
    if (text.charAt(i) == '(') {
        stack.push("(");
    } else if (text.charAt(i) == ')') {
        if (stack.isEmpty()) {
            break;
...
intindexOfIgnoreCase(final String src, char c, int startIndex, int endIndex)
index Of Ignore Case
if (startIndex < 0) {
    startIndex = 0;
final int srclen = src.length();
if (endIndex > srclen) {
    endIndex = srclen;
c = Character.toLowerCase(c);
...
intindexOfIgnoreCase(String str, String substring)
Helper method to obtain the starting index of a substring within another string, ignoring their case.
return indexOfIgnoreCase(str, substring, Locale.getDefault());
intindexOfMultiple(String line, char character, int count, int startIndex)
index Of Multiple
if (count == 1) {
    return line.indexOf(character, startIndex);
char[] array = new char[count];
Arrays.fill(array, character);
String search = String.valueOf(array);
return line.indexOf(search, startIndex);