bc62910e527408f471f85c06a18d8836a18349e2
[jalview.git] / src / com / stevesoft / pat / DirFileRegex.java
1 //
2 // This software is now distributed according to
3 // the Lesser Gnu Public License.  Please see
4 // http://www.gnu.org/copyleft/lesser.txt for
5 // the details.
6 //    -- Happy Computing!
7 //
8 package com.stevesoft.pat;
9
10 /**
11  * This class is just like FileRegex, except that its accept method only returns
12  * true if the file matching the pattern is a directory.
13  */
14 public class DirFileRegex extends FileRegex
15 {
16   public DirFileRegex()
17   {
18     dirflag = DIR;
19   }
20
21   public DirFileRegex(String fp)
22   {
23     super(fp);
24     dirflag = DIR;
25   }
26
27   public static String[] list(String f)
28   {
29     return list(f, DIR);
30   }
31 }