Here you can find the source of quoted(String str)
public static boolean quoted(String str)
//package com.java2s; //License from project: Apache License public class Main { public static boolean quoted(String str) { if (str.startsWith("\"") && str.endsWith("\"")) { return true; }//from w ww.j a v a 2 s .co m if (str.startsWith("'") && str.endsWith("'")) { return true; } return false; } }