Class Util

java.lang.Object
com.sun.tools.corba.ee.idl.Util
Direct Known Subclasses:
Util

public class Util extends Object
  • Field Details

  • Constructor Details

    • Util

      public Util()
  • Method Details

    • getVersion

      public static String getVersion()
      Fetch the version number of this build of the IDL Parser Framework from the appropriate properties file.
      Returns:
      the version number contained within the appropriate properties file, which indicates the build of this IDL Parser Framework.
    • getVersion

      protected static String getVersion(String filename)
      Fetch the version number of this build of the IDL Parser Framework. This method may be called before or after the framework has been initialized. If the framework is initialized, the version information is extracted from the message properties object; otherwise, it is extracted from the indicated messages file.
      Parameters:
      filename - name of file to get version number of
      Returns:
      the version number.
    • isAttribute

      public static boolean isAttribute(String name, Hashtable symbolTable)
    • isConst

      public static boolean isConst(String name, Hashtable symbolTable)
    • isEnum

      public static boolean isEnum(String name, Hashtable symbolTable)
    • isException

      public static boolean isException(String name, Hashtable symbolTable)
    • isInterface

      public static boolean isInterface(String name, Hashtable symbolTable)
    • isMethod

      public static boolean isMethod(String name, Hashtable symbolTable)
    • isModule

      public static boolean isModule(String name, Hashtable symbolTable)
    • isParameter

      public static boolean isParameter(String name, Hashtable symbolTable)
    • isPrimitive

      public static boolean isPrimitive(String name, Hashtable symbolTable)
    • isSequence

      public static boolean isSequence(String name, Hashtable symbolTable)
    • isStruct

      public static boolean isStruct(String name, Hashtable symbolTable)
    • isString

      public static boolean isString(String name, Hashtable symbolTable)
    • isTypedef

      public static boolean isTypedef(String name, Hashtable symbolTable)
    • isUnion

      public static boolean isUnion(String name, Hashtable symbolTable)
    • getMessage

      public static String getMessage(String key)
    • getMessage

      public static String getMessage(String key, String fill)
    • getMessage

      public static String getMessage(String key, String[] fill)
    • getDefaultMessage

      private static String getDefaultMessage(String keyNotFound)
    • readMessages

      private static void readMessages()
    • loadMessages

      private static void loadMessages(String msgResource)
    • registerMessageResource

      public static void registerMessageResource(String resourceName)
      Register a message resource. This resource will be searched for in the CLASSPATH.
      Parameters:
      resourceName - new resource name to add
    • capitalize

      public static String capitalize(String lc)
    • getAbsolutePath

      public static String getAbsolutePath(String filename, Vector<String> includePaths) throws FileNotFoundException
      Searches the current user directory and a list of directories for a given short file name and returns its absolute file specification.
      Parameters:
      filename - file to get absolute path of
      includePaths - a Vector of paths to look for the file
      Returns:
      Absolute file name of a given short filename
      Throws:
      FileNotFoundException - The file does not exist in the current user or specified directories.
      See Also:
    • absDelta

      public static float absDelta(float f1, float f2)
      Compute the absolute value of the difference between two floating-point numbers having single precision.
      Parameters:
      f1 - first floating-point number
      f2 - second floating-point number
      Returns:
      the absolute value of the difference between two floats.