## org.codehaus.groovy.grails.plugins
Class BasePluginFilter

    java.lang.Object
      org.codehaus.groovy.grails.plugins.BasePluginFilter

All Implemented Interfaces:
  PluginFilter

Direct Known Subclasses:
  ExcludingPluginFilter, IncludingPluginFilter

    public abstract class BasePluginFilter

extends Object
implements PluginFilter

Base functionality shared by `IncludingPluginFilter` and `ExcludingPluginFilter`

Author:
  Phil Zoio

Field Summary
`protected Map` `nameMap` Holds a name to GrailsPlugin map (String, Plugin)

Constructor Summary
`BasePluginFilter(Set suppliedNames)`
`BasePluginFilter(String[] included)`

Method Summary
`protected abstract void` `addPluginDependencies(List additionalList, GrailsPlugin plugin)` Defines operation for adding dependencies for a plugin to the list
`List` `filterPluginList(List original)` Template method shared by subclasses of `BasePluginFilter`.
`protected Collection` `getAllPlugins()`
`protected GrailsPlugin` `getNamedPlugin(String name)`
`protected abstract List` `getPluginList(List original, List pluginList)` Defines an operation getting the final list to return from the original and derived lists
`protected Set` `getSuppliedNames()`
`protected boolean` `isDependentOn(GrailsPlugin plugin, String pluginName)` Checks whether a plugin is dependent on another plugin with the specified name
`protected void` `registerDependency(List additionalList, GrailsPlugin plugin)` Adds a plugin to the additional if this hasn't happened already

Methods inherited from class java.lang.Object
`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

Field Detail

### nameMap

    protected Map nameMap

  Holds a name to GrailsPlugin map (String, Plugin)

Constructor Detail

### BasePluginFilter

    public BasePluginFilter(Set suppliedNames)

### BasePluginFilter

    public BasePluginFilter(String[] included)

Method Detail

### addPluginDependencies

    protected abstract void addPluginDependencies(List additionalList,
                                                  GrailsPlugin plugin)

  Defines operation for adding dependencies for a plugin to the list

### getPluginList

    protected abstract List getPluginList(List original,
                                          List pluginList)

  Defines an operation getting the final list to return from the original and derived lists

### filterPluginList

    public List filterPluginList(List original)

  Template method shared by subclasses of `BasePluginFilter`.

  Specified by:
    `filterPluginList` in interface `PluginFilter`
  Parameters:
    `original` - the original supplied set of `GrailsPlugin` instances
  Returns:
    a sublist of these items

### isDependentOn

    protected boolean isDependentOn(GrailsPlugin plugin,
                                    String pluginName)

  Checks whether a plugin is dependent on another plugin with the specified name

  Parameters:
    `plugin` - the plugin to compare
    `pluginName` - the name to compare against
  Returns:
    true if `plugin` depends on `pluginName`

### registerDependency

    protected void registerDependency(List additionalList,
                                      GrailsPlugin plugin)

  Adds a plugin to the additional if this hasn't happened already

### getAllPlugins

    protected Collection getAllPlugins()

### getNamedPlugin

    protected GrailsPlugin getNamedPlugin(String name)

### getSuppliedNames

    protected Set getSuppliedNames()

Copyright (c) 2005-2006 The Grails project