Here you can find the source of startWith(String t, String[] prefix)
public static boolean startWith(String t, String[] prefix)
//package com.java2s; //License from project: Open Source License public class Main { public static boolean startWith(String t, String[] prefix) { for (String p : prefix) { if (t.startsWith(p)) { return true; }// ww w . ja v a 2 s . co m } return false; } }