ant-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Xavier Loiseau <>
Subject Package dependencies checking
Date Sat, 26 Oct 2002 14:40:24 GMT

Suppose a team develops a set of Java packages. An
important issue is to try to make those packages as
much independent as possible. The team members can be
aware of the dependency constraints they should
respect. Nevertheless, team members can make mistakes.
Some of those mistakes can be hardly detected without
any tool enabling to check the package dependencies
automatically. I am looking for such a tool.

Let us take a simple example of 3 packages named A, B,
and C. Those packages should only have the following
dependencies: C depends on A and B.

I would like to check that:
- C depends on A and B,
- A does not depend on B and C,
- B does not depend on A and C.

I would like to check all those dependency constraints
through using a single ant task as follows:

        <dependency frompackage="C" topackage="A"/>
        <dependency frompackage="C" topackage="B"/>

If the dependency constraints were not all satisfied,
then this task would fail and return the illegal

I have looked for information about this topic through
google, the ant web site and the ant user mailing list
but did not find any good solution.

The only solution I have found is provided by the
JDepend tool as explained in .

Although JDepend seems to be a very interesting tool,
I don't want to solve this problem through this tool
for the following reasons:
- the dependency constraints have to be programmed in
Java and it would be much more convenient to provide
those constraints in an ant XML file. 
- JDepend is unable to find all package dependencies
as explained in

Could anybody tell me how to solve this problem
properly ?

Kind regards.


Do You Yahoo!? -- Une adresse gratuite et en français !
Yahoo! Mail :

To unsubscribe, e-mail:   <>
For additional commands, e-mail: <>

View raw message