java手动生成关系图,Graffiti:生成一个jar文件中类之间关系图的Java类库

Graffiti是一个用Java编写的库,用于生成JAR文件中类之间的关系图。它通过视觉表示形式生动地展示这些关系,并提供关于JAR的有用统计信息,如Maven依赖、类、接口、抽象类数量等。它支持生成Bootstrap HTML文件和独立的DOT文件。Graffiti可在Mac、Linux和Windows上运行,有两种安装方式:Web版本和独立版本。输出为HTML文件集合,包含JAR的相关信息。
摘要由CSDN通过智能技术生成

Graffiti - a jar file dependency generator

Graffiti is a java library for generating relationships betwwen the classes in a jar file. Graffiti helps you bring the relationships to life using visual representations. It generates bootsrap based html files containing the visual representation of the relationships among the classes. It also generates many other useful statistics about the jar like :

Information about maven dependencies

Number of classes; interfaces; abstract classes

Required java version

Attributes and Methos level details

It is NOT a UML diagram modelling tool

Features

Writte in core java

Generates beautiful Bootstrap html files.

Generates individual dot files as well for directed graphs.

Easy to use.

Works on Mac, Linux and Windows

Installation

There are two versions of graffiti available. The WebVersion allows you to upload your jar file and without any hassle it generates the output which will be available for download as a zip package. All you need to do is to browse to the index.html of the extracted package and open it in a browser.

The other option is to download the graffiti package from github repository and build the same using java 1.8 version. This requires the following pre-requisites to be available on your machine :

After the download please follow the following instructions to build and run graffiti on your machine :

$ cd /path/to/downloaded/graffiti

$ java -jar graffiti-core-0.0.1.jar /path/to/jar/to/analyse /path/to/output/dir /path/to/dot/executable

Output##

The output for both the web based version and standalone version is a collection of bootstrap based html files that contains the required informaion about the jar file. In case of the web based version, the same is packaged as a zip file and is available instantaneously for download. The basic structure of the output directory is as follows :

.

├── index.html and other html files

├── css

├── dot

├── images

└── js

#License# The MIT License (MIT)

Copyright (c) 2016 Sumit Gaur

Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值