Net::GraphSpace::Graph
version 0.0009
my $graph = Net::GraphSpace::Graph->new( description => 'a great graph', tags => ['foo', 'bar'], ); my $node1 = Net::GraphSpace::Node->new(id => 'node-a', label => 'A'); my $node2 = Net::GraphSpace::Node->new(id => 'node-b', label => 'B'); $graph->add_nodes([$node1, $node2]); my $edge = Net::GraphSpace::Edge->new( id => 'a-b', source => 'node-a', target => 'node-b'); $graph->add_edge($edge); $graph->add_node(Net::GraphSpace::Node->new(id => 3, label => 'C'));
Represents a graph in GraphSpace.
Optional:
Graph description. Can contain some html.
An arrayref of tag names.
Naveed Massjouni <naveedm9@gmail.com>
This software is copyright (c) 2011 by Naveed Massjouni.
This is free software; you can redistribute it and/or modify it under the same terms as the Perl 5 programming language system itself.
To install Net::GraphSpace, copy and paste the appropriate command in to your terminal.
cpanm
cpanm Net::GraphSpace
CPAN shell
perl -MCPAN -e shell install Net::GraphSpace
For more information on module installation, please visit the detailed CPAN module installation guide.