org.mmbase.util
Class Escape
java.lang.Object
org.mmbase.util.Escape
Deprecated. Use org.mmbase.util.Encode
- public class Escape
- extends Object
Class for escaping single quotes in a string, so that they can be safely
included in a SQL statement.
- Version:
- $Id: Escape.java,v 1.7 2004/09/29 14:29:23 pierre Exp $
|
Constructor Summary |
Escape()
Deprecated. |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Escape
public Escape()
- Deprecated.
singlequote
public static String singlequote(String in)
- Deprecated.
- Escapes single quotes in a string.
Escaping is done by doubling any quotes encountered.
Strings that are rendered in such way can more easily be included
in a SQL query.
- Parameters:
in - the string to escape
- Returns:
- the escaped string
- Warning: Contains Duplicate Code (present in other classes)
- use
Encode Encode encoder = new Encode("ESCAPE_SINGLE_QUOTE");
encoder.encode("MMBase it's escaping quotes");
MMBase build 1.8.1.20060716