From: Farrel Lifson Date: 2005-05-16T05:05:46+09:00 Subject: [ANN] Precedence 0.6 I've made the initial release of Precedence which is a small API to construct and analyse precedence networks, which are used quite a bit in project management and other areas. Here's the README file: = Precedence Precedence is a library that allows for the creation, manipulation and analysis of precedence networks. == Download and Install Available as a RubyGem from Rubyforge. To install $ gem install precedence will fetch the latest gem from Rubyforge and install it. Source can also be downloaded from http://rubyforge.org/projects/precedence. == Example Usage require('precedence') # Set up network net = Precedence::Network.new('Begin','End') net.new_activity('act-1-1',3,'System specification') net.new_activity('act-1-2',2,'Review') net.new_activity('act-1-3',2,'System re-specification') net.new_activity('act-2-1',3,'Test tool design') net.new_activity('act-2-2',5,'Test tool implementation') net.new_activity('act-3-1',3,'System design') net.new_activity('act-3-2',12,'System implementation') net.new_activity('act-2-3',10,'System testing') net.connect('act-1-1','act-1-2') net.connect('act-1-2','act-1-3') net.connect('act-1-3','act-3-1') net.connect('act-1-2','act-2-1') net.connect('act-2-1','act-2-2') net.connect('act-2-2','act-3-2') net.connect('act-3-1','act-3-2') net.connect('act-3-2','act-2-3') net.fix_connections! # Generate a diagram File.open('network.dot',File::CREAT|File::TRUNC|File::WRONLY) do|file| file.puts(net.to_dot) end system("dot","-Tpng","-onetwork.png","network.dot") # Perform some analysis of the activities activity = net.activities['act-1-2'] activity.on_critical_path? # => true activity.earliest_start # => 3.0 activity.latest_finish # => 5.0 activity.total_float # => 0 - activities on the critical path have no float == Documentation The Precedence API online documentation is available at http://precedence.rubyforge.org. Refer to the CHANGELOG and TODO files for past changes and upcoming plans. == Credits Farrel Lifson == License This software is made available under the BSD license.