Java String Starts Wtih startsWith(String partial, String possible)

Here you can find the source of startsWith(String partial, String possible)

Description

starts With

License

Creative Commons License

Declaration

public static boolean startsWith(String partial, String possible) 

Method Source Code

//package com.java2s;
/**/*  w w  w.ja  v  a 2  s. c  o  m*/
 * Copyright 2015 by UnoModding and Contributors
 *
 * This work is licensed under the Creative Commons Attribution-ShareAlike 3.0 Unported License.
 * To view a copy of this license, visit http://creativecommons.org/licenses/by-sa/3.0/.
 */

public class Main {
    public static boolean startsWith(String partial, String possible) {
        return possible.regionMatches(true, 0, partial, 0, partial.length());
    }
}

Related

  1. startsWith(String check, String doesStartWith)
  2. startsWith(String cid1, String cid2)
  3. startsWith(String comparee, char comparant)
  4. startsWith(String inStart, String inValue)
  5. startsWith(String n, char tag)
  6. startsWith(String path, String prefix)
  7. startsWith(String prefix, String string, boolean caseInsensitive)
  8. startsWith(String receiver, String... needles)
  9. startsWith(String s, boolean caseIgnore, String... args)