Here you can find the source of quote(String val)
Parameter | Description |
---|---|
val | String to wrap in double-quotes |
static public String quote(String val)
//package com.java2s; /** Copyright (C) (SAS) All rights reserved. ** General Public License: http://www.opensource.org/licenses/gpl-license.php **//* w w w .j a va 2s. c o m*/ public class Main { /** * Wrap the provided val String in double-quotes. * @param val String to wrap in double-quotes * @return val wrapped in quotes or a double-quoted empty string if * val was null. */ static public String quote(String val) { if (val == null) return "\"\""; return "\"" + val + "\""; } }