1 15 package org.josql.filters; 16 17 import java.io.File ; 18 19 import javax.swing.filechooser.FileFilter ; 20 21 import org.josql.Query; 22 import org.josql.QueryParseException; 23 24 34 public class JoSQLSwingFileFilter extends FileFilter 35 { 36 37 private JoSQLFileFilter ff = null; 39 40 private String d = null; 41 42 49 public JoSQLSwingFileFilter (String q) 50 throws QueryParseException 51 { 52 53 this.ff = new JoSQLFileFilter (q); 54 55 } 56 57 64 public JoSQLSwingFileFilter (Query q) 65 throws IllegalStateException , 66 QueryParseException 67 { 68 69 this.ff = new JoSQLFileFilter (q); 70 71 } 72 73 78 public void setJoSQLFileFilter (JoSQLFileFilter ff) 79 { 80 81 this.ff = ff; 82 83 } 84 85 90 public void setDescription (String d) 91 { 92 93 this.d = d; 94 95 } 96 97 102 public String getDescription () 103 { 104 105 return this.d; 106 107 } 108 109 115 public JoSQLFileFilter getJoSQLFileFilter () 116 { 117 118 return this.ff; 119 120 } 121 122 129 public boolean accept (File f) 130 { 131 132 return this.ff.accept (f); 133 134 } 135 136 } 137 | Popular Tags |