Class JavaEscapeUtils


  • @Deprecated
    public class JavaEscapeUtils
    extends java.lang.Object
    Deprecated.
    since version 2.1.0 of the API; see JavaEscapeHelper for a replacement.
    The JavaEscapeUtils provides useful methods for escaping or transforming invalid Java tokens to valid ones that could be used in generated Java source code.
    • Constructor Summary

      Constructors 
      Constructor Description
      JavaEscapeUtils()
      Deprecated.
       
    • Method Summary

      All Methods Static Methods Concrete Methods Deprecated Methods 
      Modifier and Type Method Description
      static boolean isJavaKeyword​(java.lang.String key)
      Deprecated.
      Test whether the argument is a Java keyword.
      static java.lang.String makeJavaIdentifier​(java.lang.String identifier)
      Deprecated.
      Converts the given identifier to a legal Java identifier
      static java.lang.String makeJavaPackage​(java.lang.String scriptName)
      Deprecated.
      Converts the given scriptName to a Java package or fully-qualified class name
      static java.lang.String mangleChar​(char ch)
      Deprecated.
      Mangle the specified character to create a legal Java class name.
      static char unmangle​(java.lang.String mangled)
      Deprecated.
      Provided a mangled string (obtained by calling mangleChar(char)) it will will return the character that was mangled.
      • Methods inherited from class java.lang.Object

        equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

      • JavaEscapeUtils

        public JavaEscapeUtils()
        Deprecated.
    • Method Detail

      • makeJavaIdentifier

        public static java.lang.String makeJavaIdentifier​(java.lang.String identifier)
        Deprecated.
        Converts the given identifier to a legal Java identifier
        Parameters:
        identifier - the identifier to convert
        Returns:
        legal Java identifier corresponding to the given identifier
      • mangleChar

        public static java.lang.String mangleChar​(char ch)
        Deprecated.
        Mangle the specified character to create a legal Java class name.
        Parameters:
        ch - the character to mangle
        Returns:
        the mangled
      • unmangle

        public static char unmangle​(java.lang.String mangled)
        Deprecated.
        Provided a mangled string (obtained by calling mangleChar(char)) it will will return the character that was mangled.
        Parameters:
        mangled - the mangled string
        Returns:
        the original character
      • makeJavaPackage

        public static java.lang.String makeJavaPackage​(java.lang.String scriptName)
        Deprecated.
        Converts the given scriptName to a Java package or fully-qualified class name
        Parameters:
        scriptName - the scriptName to convert
        Returns:
        Java package corresponding to the given scriptName
      • isJavaKeyword

        public static boolean isJavaKeyword​(java.lang.String key)
        Deprecated.
        Test whether the argument is a Java keyword.
        Parameters:
        key - the String to test
        Returns:
        true if the String is a Java keyword, false otherwise