module TokyoMetro::Document::Gviz::RubyGraph

Ruby のクラス図を生成するためのモジュール

Public Class Methods

process( dot_file: true ) click to toggle source

処理を行うメソッド @param dot_file [Boolean] .dot ファイルの生成を行うか否かの設定 @return [nil]

# File lib/tokyo_metro/document/gviz/ruby_graph.rb, line 7
def self.process( dot_file: true )
  if dot_file
    make_dot_file
  end
  return nil
end

Private Class Methods

make_dot_file() click to toggle source

.dot ファイルを生成するメソッド @return [nil]

# File lib/tokyo_metro/document/gviz/ruby_graph.rb, line 20
def make_dot_file
  filename = "ruby_classes.dot"
  Dir.chdir( ::TokyoMetro.DEV_DIR ) do
    system( "yard graph --full --dependencies --verbose -f #{filename}" )
    File.rename( filename , "#{ ::TokyoMetro::Document::Gviz::DIR }/#{filename}" )
  end
  return nil
end