Class Glob


  • public class Glob
    extends java.lang.Object
    • Field Summary

      Fields 
      Modifier and Type Field Description
      static Glob ALL  
    • Constructor Summary

      Constructors 
      Constructor Description
      Glob​(java.lang.String globString)  
      Glob​(java.lang.String globString, int flags)  
    • Method Summary

      All Methods Static Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      java.util.List<java.io.File> getFiles​(java.io.File root, boolean recursive, boolean usePath)
      Get a list of files that match the glob expression
      void getFiles​(java.io.File root, java.util.List<java.io.File> result, boolean recursive, boolean usePath)  
      java.util.regex.Matcher matcher​(java.lang.CharSequence input)  
      void select​(java.util.List<?> objects)  
      static java.util.regex.Pattern toPattern​(java.lang.String s)  
      static java.util.regex.Pattern toPattern​(java.lang.String s, int flags)  
      java.lang.String toString()  
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
    • Field Detail

      • ALL

        public static final Glob ALL
    • Constructor Detail

      • Glob

        public Glob​(java.lang.String globString)
      • Glob

        public Glob​(java.lang.String globString,
                    int flags)
    • Method Detail

      • matcher

        public java.util.regex.Matcher matcher​(java.lang.CharSequence input)
      • toString

        public java.lang.String toString()
        Overrides:
        toString in class java.lang.Object
      • select

        public void select​(java.util.List<?> objects)
      • toPattern

        public static java.util.regex.Pattern toPattern​(java.lang.String s)
      • toPattern

        public static java.util.regex.Pattern toPattern​(java.lang.String s,
                                                        int flags)
      • getFiles

        public java.util.List<java.io.File> getFiles​(java.io.File root,
                                                     boolean recursive,
                                                     boolean usePath)
        Get a list of files that match the glob expression
        Parameters:
        root - the directory to get the files from
        recursive - to traverse the dirs recursive
        Returns:
        file list
      • getFiles

        public void getFiles​(java.io.File root,
                             java.util.List<java.io.File> result,
                             boolean recursive,
                             boolean usePath)