Sha256: 52af758af372f95b353f2ae23f94efd197a7b0a80f24881f244096af183bef79
Contents?: true
Size: 921 Bytes
Versions: 1
Compression:
Stored size: 921 Bytes
Contents
# Graphviz::Diagram A simple utility to create class-diagrams based on Graphviz. ## Installation Add this line to your application's Gemfile: gem 'graphviz-diagram' And then execute: $ bundle Or install it yourself as: $ gem install graphviz-diagram ## Usage Create a diagram: g = Graphviz::Diagram.new g['Author'].add_attribute 'name', visibility: :private, type: 'String' g['Author'].add_attribute 'age', visibility: :private, type: 'Age' g['Author'].add_method 'books', type: 'Array' g['Author'].add_method 'update', arguments: 'name, age', type: 'Boolean' g['Book'].add_attribute 'title', type: 'String' g['Book'].add_method 'author', type: 'Author' g << g['Book'].belongs_to(g['Author']) g.output png: 'book_author.png' It create a `book_author.png` file looks like:  (`examples` folder contains more examples)
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
graphviz-diagram-0.0.1 | README.md |