org.apache.commons.betwixt.strategy.impl.propertysuppression
Class PackageSuppressor
java.lang.Object
org.apache.commons.betwixt.strategy.PropertySuppressionStrategy
org.apache.commons.betwixt.strategy.impl.propertysuppression.PackageSuppressor
public class PackageSuppressor
- extends PropertySuppressionStrategy
Suppresses properties based on the package of their type.
Limited regex is supported. If the package name ends in .*
them all child packages will be suppressed.
- Since:
- 0.8
- Author:
- Apache Commons Team of the Apache Software Foundation
Constructor Summary |
PackageSuppressor(java.lang.String suppressedPackage)
Constructs a suppressor for packages. |
Method Summary |
boolean |
suppressProperty(java.lang.Class classContainingTheProperty,
java.lang.Class propertyType,
java.lang.String propertyName)
Should the given property be suppressed? |
java.lang.String |
toString()
|
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
PackageSuppressor
public PackageSuppressor(java.lang.String suppressedPackage)
- Constructs a suppressor for packages.
- Parameters:
suppressedPackage
- package name (for exact match)
or base package and .*
to suppress children
suppressProperty
public boolean suppressProperty(java.lang.Class classContainingTheProperty,
java.lang.Class propertyType,
java.lang.String propertyName)
- Description copied from class:
PropertySuppressionStrategy
- Should the given property be suppressed?
- Specified by:
suppressProperty
in class PropertySuppressionStrategy
- Parameters:
classContainingTheProperty
- Class
giving the type of the bean containing the property propertyName
propertyType
- Class
giving the type of the property, not nullpropertyName
- the name of the property, not null
- Returns:
- true when the given property should be suppressed
toString
public java.lang.String toString()
- Overrides:
toString
in class java.lang.Object
Copyright © 2002-2008 The Apache Software Foundation. All Rights Reserved.