uk.org.retep.util.io
Class PackageFileFilter

java.lang.Object
  extended by uk.org.retep.util.io.PatternFileFilter
      extended by uk.org.retep.util.io.PackageFileFilter
All Implemented Interfaces:
java.io.FileFilter
Direct Known Subclasses:
PackageFileFilter.Exclude, PackageFileFilter.Include

public abstract class PackageFileFilter
extends PatternFileFilter

A PatternFileFilter that converts string patterns based on package names. That is, uk.org.retep.* would match all packages starting with that package name, and *.annotations would match all packages ending with that name.

Author:
peter

Nested Class Summary
static class PackageFileFilter.Exclude
          An Exclude filter, where all files that do not match, but are under the base directory are included.
static class PackageFileFilter.Include
          An Include filter, where all files that match are included.
 
Field Summary
 
Fields inherited from class uk.org.retep.util.io.PatternFileFilter
DOT, DOT_REGEX
 
Method Summary
 void add(java.lang.String glob)
          Add a glob to the filter.
 
Methods inherited from class uk.org.retep.util.io.PatternFileFilter
add, addAll, addAll, addAll, convertPackage, getMatcher, inScope, matches
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface java.io.FileFilter
accept
 

Method Detail

add

public final void add(java.lang.String glob)
Add a glob to the filter. Here, valid globs are a java package name. If the package starts with "*.", then any package that ends with that name will be accepted. If it ends with ".*", then any package that starts with that name will be accepted. Otherwise, an exact match for the package is assumed.

Overrides:
add in class PatternFileFilter
Parameters:
glob -


Copyright © 1998-2010 Retep Development Group. All Rights Reserved.