Class FilenameUtils


  • public class FilenameUtils
    extends java.lang.Object
    • Constructor Summary

      Constructors 
      Constructor Description
      FilenameUtils()  
    • Method Summary

      All Methods Static Methods Concrete Methods 
      Modifier and Type Method Description
      static boolean wildcardMatch​(java.lang.String fileName, java.lang.String wildcardMatcher, IOCase ioCase)
      Checks a fileName to see if it matches the specified wildcard matcher allowing control over case-sensitivity.
      • Methods inherited from class java.lang.Object

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

      • FilenameUtils

        public FilenameUtils()
    • Method Detail

      • wildcardMatch

        public static boolean wildcardMatch​(java.lang.String fileName,
                                            java.lang.String wildcardMatcher,
                                            IOCase ioCase)
        Checks a fileName to see if it matches the specified wildcard matcher allowing control over case-sensitivity.

        The wildcard matcher uses the characters '?' and '*' to represent a single or multiple (zero or more) wildcard characters. N.B. the sequence "*?" does not work properly at present in match strings.

        Parameters:
        fileName - the fileName to match on
        wildcardMatcher - the wildcard string to match against
        ioCase - what case sensitivity rule to use, null means case-sensitive
        Returns:
        true if the fileName matches the wildcard string
        Since:
        1.3