single quotes surrounder function to StringUtil
authorNikolay Matveev <Nikolay.Matveev@jetbrains.com>
Sun, 9 Oct 2011 13:23:39 +0000 (17:23 +0400)
committerNikolay Matveev <Nikolay.Matveev@jetbrains.com>
Sun, 9 Oct 2011 13:23:39 +0000 (17:23 +0400)
platform/util/src/com/intellij/openapi/util/text/StringUtil.java

index 25ac841ae8a293ad6c49e32b1b4b20e4702a6f9a..0f1217028d90b38ae3fc5edd7c4263172ba5433e 100644 (file)
@@ -47,6 +47,13 @@ public class StringUtil {
     }
   };
 
+  public static final NotNullFunction<String, String> SINGLE_QUOTER = new NotNullFunction<String, String>() {
+    @NotNull
+    public String fun(String s) {
+      return "'" + s + "'";
+    }
+  };
+
   public static <T> Function<T, String> createToStringFunction(Class<T> cls) {
     return new Function<T, String>() {
       @Override