public class DependencyConstraint
extends java.lang.Object
DependencyConstraint
class is a constraint
that tests collections of package dependencies.Constructor and Description |
---|
DependencyConstraint()
Constructs a
DependencyConstraint instance. |
Modifier and Type | Method and Description |
---|---|
void |
addPackage(JavaPackage jPackage)
Adds the specified Java package to the
constraint.
|
JavaPackage |
addPackage(java.lang.String packageName)
Adds the specified Java package to the
constraint, creating it if necessary.
|
java.util.Collection |
getPackages()
Returns the constraint packages.
|
boolean |
match(java.util.Collection packages)
Indicates whether the specified packages match
the packages in this constraint.
|
protected boolean |
matchPackage(JavaPackage expectedPackage) |
public DependencyConstraint()
DependencyConstraint
instance.public JavaPackage addPackage(java.lang.String packageName)
packageName
- Java package name.public void addPackage(JavaPackage jPackage)
jPackage
- Java package.public java.util.Collection getPackages()
public boolean match(java.util.Collection packages)
true
if the packages
match this constraintprotected boolean matchPackage(JavaPackage expectedPackage)
Copyright ? 1999-2002 Clarkware Consulting, Inc. All Rights Reserved.