Sha256: 85e819e5b14b39adf293615f001fe130fc136faecb1204dcc4909b4f18ca39a6

Contents?: true

Size: 763 Bytes

Versions: 10

Compression:

Stored size: 763 Bytes

Contents

# http://www.graphviz.org/Gallery/undirected/process.html
#
# graph G {
# 	run -- intr;
# 	intr -- runbl;
# 	runbl -- run;
# 	run -- kernel;
# 	kernel -- zombie;
# 	kernel -- sleep;
# 	kernel -- runmem;
# 	sleep -- swap;
# 	swap -- runswap;
# 	runswap -- new;
# 	runswap -- runmem;
# 	new -- runmem;
# 	sleep -- runmem;
# }

$:.unshift( "../../lib" );
require "graphviz"

GraphViz::new( :G, :type => :graph ) { |g|
  g._new[:label] = "new"
  g.run << g.intr
  g.intr << g.runbl
  g.runbl << g.run
  g.run << g.kernel
  g.kernel << g.zombie
  g.kernel << g.sleep
  g.kernel << g.runmem
  g.sleep << g.swap
  g.swap << g.runswap
  g.runswap << g._new
  g.runswap << g.runmem
  g._new << g.runmem
  g.sleep << g.runmem
}.output( :png => "process.png", :use => :fdp )

Version data entries

10 entries across 10 versions & 1 rubygems

Version Path
ruby-graphviz-0.9.11 examples/graphviz.org/process.rb
ruby-graphviz-0.9.10 examples/graphviz.org/process.rb
ruby-graphviz-0.9.9 examples/graphviz.org/process.rb
ruby-graphviz-0.9.8 examples/graphviz.org/process.rb
ruby-graphviz-0.9.7 examples/graphviz.org/process.rb
ruby-graphviz-0.9.6 examples/graphviz.org/process.rb
ruby-graphviz-0.9.5 examples/graphviz.org/process.rb
ruby-graphviz-0.9.4 examples/graphviz.org/process.rb
ruby-graphviz-0.9.3 examples/graphviz.org/process.rb
ruby-graphviz-0.9.2 examples/graphviz.org/process.rb