Summarizes a dependency graph according to user-specified criteria.
This tool takes a dependency graph generated by
DependencyExtractor and filters it based
on selection criteria provided by the user. The result is a new dependency
graph which is a subgraph of the original one. You can use the various
XXXToText
and XXXToHTML
XSL transformations to render
the graph as text or HTML for human reading.
This tool can read multiple graphs and apply the same selection criteria across them to generate an aggregated result. With sufficiently wide criteria, you can use this tool to combine multiple graphs into one.
Refer to the Reporting
section of the manual for an explanation of the various scope
and
filter
attributes. Basically, scoping refers to the selection of
nodes from the source graph that will make up the basis for the resulting graph.
Filtering refers to the selection of links to or from the nodes in the scope.
In practical terms, you use scoping to zero in on the set of elements that you are interested in tracing dependencies to or from. You then filter in or out the dependencies stemming (whether inbound or outbound) from the scoped nodes.
The filterexcludes
attribute is where you typically filter out
large swaths of links that you do not want in the report, such as
"/^java.*/,/^org.*/
".
With the xml
attribute, it converts the entire dependency
graph into an XML document that follows the
dependencies
DTD.
Attribute | Description | Required |
srcfile | filename of the XML document containing the dependency graph. | Yes, unless nested <src> elements are present. |
validate | validate the input XML against its DTD. | No; defaults to false. |
destfile | where to write the output. If the file does not exists, it is created. If it already exists, its content is overwritten. | Yes |
scopeincludes | the name of a package, class, or feature must match the regular expressions for it to be included in the query's focus. | No |
scopeexcludes | the name of a package, class, or feature must NOT match the regular expressions for it to be included in the query's focus. | No |
packagescope | select packages as part of the query's focus. | No |
packagescopeincludes | the name of a package must match the regular expressions for it to be included in the query's focus. | No |
packagescopeexcludes | the name of a package must NOT match the regular expressions for it to be included in the query's focus. | No |
classscope | select classes (with their package) as part of the query's focus. | No |
classscopeincludes | the name of a class must match the regular expressions for it to be included in the query's focus. | No |
classscopeexcludes | the name of a class must NOT match the regular expressions for it to be included in the query's focus. | No |
featurescope | select features (with their class and package) as part of the query's focus. | No |
featurescopeincludes | the name of a feature must match the regular expressions for it to be included in the query's focus. | No |
featurescopeexcludes | the name of a feature must NOT match the regular expressions for it to be included in the query's focus. | No |
scopeincludeslist | the name of a package, class, or feature must match an entry in the named files for it to be included in the query's focus. | No |
scopeexcludeslist | the name of a package, class, or feature must NOT match any of the entries in the named files for it to be included in the query's focus. | No |
filterincludes | the name of a package, class, or feature at the other end of the dependency must match the regular expressions for the dependency to be included in the results. | No |
filterexcludes | the name of a package, class, or feature at the other end of the dependency must NOT match the regular expressions for the dependency to be included in the results. | No |
packagefilter | show dependencies to and/or from packages. | No |
packagefilterincludes | the name of a package at the other end of the dependency must match the regular expressions for the dependency to be included in the results. | No |
packagefilterexcludes | the name of a package at the other end of the dependency must NOT match the regular expressions for the dependency to be included in the results. | No |
classfilter | show dependencies to and/or from classes. | No |
classfilterincludes | the name of a class at the other end of the dependency must match the regular expressions for the dependency to be included in the results. | No |
classfilterexcludes | the name of a class at the other end of the dependency must NOT match the regular expressions for the dependency to be included in the results. | No |
featurefilter | show dependencies to and/or from features. | No |
featurefilterincludes | the name of a feature at the other end of the dependency must match the regular expressions for the dependency to be included in the results. | No |
featurefilterexcludes | the name of a feature at the other end of the dependency must NOT match the regular expressions for the dependency to be included in the results. | No |
filterincludeslist | the name of a package, class, or feature at the other end of the dependency must match match an entry in the named files for the dependency to be included in the results. | No |
filterexcludeslist | the name of a package, class, or feature at the other end of the dependency must NOT match any of the entries in the named files for the dependency to be included in the results. | No |
p2p | shortcut for packagescope and
packagefilter . |
No |
c2p | shortcut for classscope and
packagefilter . |
No |
c2c | shortcut for classscope and
classfilter . |
No |
f2f | shortcut for featurescope and
featurefilter . |
No |
includes | shortcut for scopeincludes and
filterincludes . |
No |
excludes | shortcut for scopeexcludes and
filterexcludes . |
No |
copyonly | limits the report to dependencies that are actually in the source graph. This will prevent the reporter from inferring implicit dependencies when possible. | No; defaults to false. |
showemptynodes | lists nodes in the scope, even if they would appear empty because they have no inbound or outbound dependencies. | No; defaults to false. |
showinbounds | lists filtered inbound dependencies for scoped nodes. | No; defaults to false. |
showoutbounds | lists filtered outbound dependencies for scoped nodes. | No; defaults to false. |
xml | writes the dependency graph as an XML document with the
dependencies
DTD. |
No; defaults to false. |
encoding | encoding used for the XML output document.
Only useful with xml . |
No |
dtdprefix | prefix of the DTD URL for the XML output document.
Only useful with xml . |
No; defaults to "https://depfind.sourceforge.io/dtd". |
indenttext | used for each indentation level in textual and XML output. | No; defaults to " " (4 spaces). |
minimize | minimizes the dependency graph before outputing it. | No; defaults to false. |
maximize | maximizes the dependency graph before outputing it. | No; defaults to false. |
<dependencyreporter>
's srcfile
attribute is a
path-like structures
and can also be set via a nested <src>
element.
<dependencyreporter>
's scopeincludeslist
attribute is a path-like
structures and can also be set via a nested
<scopeincludeslist>
element.
<dependencyreporter>
's scopeexcludeslist
attribute is a path-like
structures and can also be set via a nested
<scopeexcludeslist>
element.
<dependencyreporter>
's filterincludeslist
attribute is a path-like
structures and can also be set via a nested
<filterincludeslist>
element.
<dependencyreporter>
's filterexcludeslist
attribute is a path-like
structures and can also be set via a nested
<filterexcludeslist>
element.
To reduce the graph in dg.xml
to package-to-package
dependencies and save it to dg.p2p.xml
:
<dependencyreporter srcfile="df.xml" destfile="df.p2p.xml" p2p="yes"/>
To reduce the graph in dg.xml
to package-to-package
dependencies among com.jeantessier.*
packages and save
it to dg.p2p.xml
, and then convert it to HTML:
<dependencyreporter srcfile="df.xml" destfile="df.p2p.xml" p2p="yes" includes="/jeantessier/"/>
To reduce the graph in dg.xml
to package-to-package
dependencies and save it to dg.p2p.xml
:
<dependencyreporter srcfile="df.xml" destfile="df.p2p.xml" p2p="yes" includes="/jeantessier/"/> <xslt style="${dependencyfinder.home}/etc/DependencyGraphToHTML.xsl" in="df.p2p.xml" out="df.p2p.html"/>
Copyright © 2001-2023 Jean Tessier. All rights reserved.