Defining what to exclude in all sequence diagrams

The omit parameter exludes the given methods from the defined sequence diagram. Additionally, JSeqUnit excludes by default the following packages from sequence diagrams:

This reduces the size of the resulting sequence diagrams and improves the speed of the sequence diagram generation.
However, sometimes it could be desirable to have such classes and methods as part of the sequence diagrams (e.g. when the Java folks use JSeqUnit :-), or it could be convenient to exclude other packages from all sequence diagrams of a given project (e.g. projects based on the eclipse/osgi plugin framework: org.eclipse.*, org.osgi.*).
The property jsequnit.default.excludes can be used to change these default excludes. e.g. -J-Djsequnit.default.excludes=java.*,javax.*,sun.*,com.sun.*,org.eclipse.*,org.osgi.*


Given the Java class net.sf.jsequnit.example.SequenceSample containing a method excludeMethodsFromDiagramWithDefaultExcludes that calls methods of the following classes:

  • net.sf.jsequnit.example.SequenceSample

where the JavaDoc of the method contains a sequence diagram tag only with a 'test=...' parameter, but without specifying excludes for the class


when JSeqUnit is executed with the following JavaDoc command

      -taglet net.sf.jsequnit.javadoc.SequenceTaglet 
      -tagletpath target/classes;target/test-classes;target/jsequnit-2.0.jar;target/lib/junit-4.10.jar;target/lib/jseq-0.6.jar;target/lib/sdedit-light-3.1.jar 
      -sourcepath src/site/example/main
      -d target/test-dir 

we get a sequence diagram containing methods calledByFoo and calledByBar of the class net.sf.jsequnit.example.SequenceSample, but without method calls to callBack of classes and

Configuring Default Excludes in Maven

Add the parameter 'additionalJOption' to the maven-javadoc-plugin, to configure default excludes. The following example shows how to add the packages 'org.eclipse.*, org.osgi.*' to the default excludes.