Class FileTypeTable


  • public class FileTypeTable
    extends java.lang.Object
    • Field Detail

      • FILE_TYPE_TABLE

        private static java.util.Hashtable<java.lang.Integer,​FileTypeInfo> FILE_TYPE_TABLE
      • FILE_EXT_TABLE

        private static java.util.Hashtable<java.lang.String,​java.lang.Integer> FILE_EXT_TABLE
    • Constructor Detail

      • FileTypeTable

        public FileTypeTable()
    • Method Detail

      • getFileTypeFromSuffix

        public static final int getFileTypeFromSuffix​(java.lang.String ext)
        Gets the file type based upon the suffix.
        Parameters:
        ext - The suffix (including the period -- e.g., ".xml")
        Returns:
        The file type for the given suffix (or UNDEFINED if the suffix is null, unrecognized, or ambiguous).
      • getFileTypeInfo

        public static final FileTypeInfo getFileTypeInfo​(int fileType)
      • addExtensionAssociation

        public static final void addExtensionAssociation​(java.lang.String ext,
                                                         int fileType)
      • standardizeExtensionFormat

        private static final java.lang.String standardizeExtensionFormat​(java.lang.String ext)
        Standardizes an file extension string to conform with how they should be stored in the file type table.
        Parameters:
        ext - The extension to standardize.
        Returns:
        The standardized extension.
      • getAllFileTypeDescriptions

        public static final java.lang.String[] getAllFileTypeDescriptions()
      • getAllFileTypeExtensions

        public static final java.util.Vector<java.lang.String> getAllFileTypeExtensions()
      • getAllFileTypeDefaultExtensions

        public static final java.lang.String[] getAllFileTypeDefaultExtensions()
      • getAllFileTypes

        public static final int[] getAllFileTypes()
      • getFileTypeTable

        public static final java.util.Hashtable<java.lang.Integer,​FileTypeInfo> getFileTypeTable()