diff --git a/src/fr/devinsy/util/strings/StringsUtils.java b/src/fr/devinsy/util/strings/StringsUtils.java index 8b93c1e..a4f522d 100644 --- a/src/fr/devinsy/util/strings/StringsUtils.java +++ b/src/fr/devinsy/util/strings/StringsUtils.java @@ -117,7 +117,31 @@ public class StringsUtils { boolean result; - result = new StringList(strings).contains(token); + boolean ended = false; + int index = 0; + result = false; + while (!ended) + { + if (index < strings.length) + { + String current = strings[index]; + + if (StringUtils.contains(token, current)) + { + ended = true; + result = true; + } + else + { + index += 1; + } + } + else + { + ended = true; + result = false; + } + } // return result; @@ -136,7 +160,31 @@ public class StringsUtils { boolean result; - result = new StringList(strings).containsIgnoreCase(token); + boolean ended = false; + int index = 0; + result = false; + while (!ended) + { + if (index < strings.length) + { + String current = strings[index]; + + if (StringUtils.containsIgnoreCase(token, current)) + { + ended = true; + result = true; + } + else + { + index += 1; + } + } + else + { + ended = true; + result = false; + } + } // return result;