Java String Start With startWithIgnoreCase(String str, String prefix)

Here you can find the source of startWithIgnoreCase(String str, String prefix)

Description

start With Ignore Case

License

Open Source License

Declaration

public static boolean startWithIgnoreCase(String str, String prefix) 

Method Source Code

//package com.java2s;
//License from project: Open Source License 

public class Main {
    public static boolean startWithIgnoreCase(String str, String prefix) {
        if (str.length() < prefix.length())
            return false;
        return prefix.equalsIgnoreCase(str.substring(0, prefix.length()));
    }/*  w  w  w.  j  av a2s  . c  o  m*/
}

Related

  1. startWith(String string, String prefix)
  2. startWith(String string1, String string2)
  3. startWithAorAn(String str)
  4. startWithBOM(byte[] array)
  5. startWithIgnoreCase(CharSequence str, CharSequence prefix)
  6. startWithLowerCase(String in)
  7. startWithLowerCase(String methodName)
  8. startWithProtocol(String input)
  9. startWithProtocol(String input)