< prev index next >

src/com/sun/javatest/exec/BasicSession.java

Print this page




 282      * @param name
 283      * @return found filter or null, if not found.
 284      */
 285     protected TestFilter findFilter(String name) {
 286         if (EL_FILTER.equals(name)) {
 287             return config.getExcludeListFilter();
 288         } else if (KWD_FILTER.equals(name)) {
 289             return config.getKeywordsFilter();
 290         } else if (PRIOR_FILTER.equals(name)) {
 291             return config.getPriorStatusFilter();
 292         } else if (RELEVANT_FILTER.equals(name)) {
 293             return config.getRelevantTestFilter();
 294         }
 295         return null;
 296     }
 297 
 298     public List<String> getTestFilterNames() {
 299         return filterNames;
 300     }
 301 
 302     public void save(Map map) {
 303         if (wd != null)
 304             map.put("workDir", wd.getPath());
 305         // save name of interview file
 306         if (config != null && config.getFile() != null)
 307             map.put("config", config.getFile().getPath());
 308     }
 309 
 310     public void restore(Map map) throws Fault {
 311         if (map == null)
 312             return;
 313 
 314         String wdPath = (String)map.get("workDir");
 315         if (wdPath == null) {
 316             return;
 317         }
 318         try {
 319             WorkDirectory workDir = WorkDirectory.open(new File(wdPath), config.getTestSuite());
 320             updateWorkDir(workDir, false);
 321             //this.wd = workDir;
 322             //applyWorkDir(wd);




 282      * @param name
 283      * @return found filter or null, if not found.
 284      */
 285     protected TestFilter findFilter(String name) {
 286         if (EL_FILTER.equals(name)) {
 287             return config.getExcludeListFilter();
 288         } else if (KWD_FILTER.equals(name)) {
 289             return config.getKeywordsFilter();
 290         } else if (PRIOR_FILTER.equals(name)) {
 291             return config.getPriorStatusFilter();
 292         } else if (RELEVANT_FILTER.equals(name)) {
 293             return config.getRelevantTestFilter();
 294         }
 295         return null;
 296     }
 297 
 298     public List<String> getTestFilterNames() {
 299         return filterNames;
 300     }
 301 
 302     public void save(Map<String, String> map) {
 303         if (wd != null)
 304             map.put("workDir", wd.getPath());
 305         // save name of interview file
 306         if (config != null && config.getFile() != null)
 307             map.put("config", config.getFile().getPath());
 308     }
 309 
 310     public void restore(Map map) throws Fault {
 311         if (map == null)
 312             return;
 313 
 314         String wdPath = (String)map.get("workDir");
 315         if (wdPath == null) {
 316             return;
 317         }
 318         try {
 319             WorkDirectory workDir = WorkDirectory.open(new File(wdPath), config.getTestSuite());
 320             updateWorkDir(workDir, false);
 321             //this.wd = workDir;
 322             //applyWorkDir(wd);


< prev index next >