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