Need help with scaladiagrams?
Click the “chat” button below for chat support from the developer who created it, or find similar developers for support.

About the developer

mikeyhu
130 Stars 33 Forks MIT License 36 Commits 7 Opened issues

Description

Generate class diagrams from scala source code

Services available

!
?

Need anything else?

Contributors list

# 539,185
Scala
graphvi...
Shell
3 commits
# 649,908
Scala
graphvi...
Shell
1 commit
# 650,101
Scala
graphvi...
Shell
cdc
1 commit
# 260,327
Shell
data-ex...
pdfbox
JavaScr...
1 commit

Scala Diagrams

Scaladiagrams is a command line tool to generate DOT files representing a Scala projects class hierarchy. These DOT files can then be passed to a renderer such as GraphViz to draw the hierarchy.

Usage

First, compile and package with ./build

To run Scaladiagrams do the following:

scaladiagrams --source pathToScalaSourcefiles > dotFile

If you have Graphviz installed, you can generate an image like so:

scaladiagrams --source pathToScalaSourcefiles | dot -Tpng > file.png

Large class hierarchies are probably best rendered as an SVG file, just replace the -t target to svg.

Other options

./scaladiagrams --help
    -e, --extension      (default = .scala) 
    -l, --linked             only output types that extend other types 
    -p, --parent        only output parents of the named class 
    -s, --source        location of source files (default = .) 

Most useful of these are --linked and --parent; these both reduce the scope of the diagram to be produced.

Example diagram

Class Diagram

We use cookies. If you continue to browse the site, you agree to the use of cookies. For more information on our use of cookies please see our Privacy Policy.