Download the PHP package dono-sybrix/php-graph without Composer
On this page you can find all versions of the php package dono-sybrix/php-graph. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Table of contents
Download dono-sybrix/php-graph
More information about dono-sybrix/php-graph
Files in dono-sybrix/php-graph
Download dono-sybrix/php-graph
More information about dono-sybrix/php-graph
Files in dono-sybrix/php-graph
Please rate this library. Is it a good library?
Informations about the package php-graph
PHPGraph
PHPGraph allow you to create conditional graphs in PHP.
// Init a graph
$graph = new \PHPGraph\Graph();
// Create nodes
$graph->createNode('Gender');
$graph->createNode('Hall A');
$graph->createNode('Hall B');
$graph->createNode('Hall C');
// Create links.
$graph->link('Gender', 'Hall A')
->addCondition($user->size, '>=', 1.90)
->addConsequence('car_color', 'red');
$graph->link('Gender', 'Hall B')
->createConditionGroup('&&')
->addCondition($user->size, '>', 1.60)
->addCondition($user->size, '<', 1.90 )
->close()
->addConsequence('car_color', 'orange');
$graph->link('Gender', 'Hall C')
->addCondition($user->size, '<', 1.60)
->addConsequence('car_color', 'yellow');
// Get data (consequences executed, nodes visited, etc)
$results = $graph->visit();
Installation
You need Composer installed :
All versions of php-graph with dependencies
PHP Build Version
Package Version
No informations.
The package dono-sybrix/php-graph contains the following files
Loading the files please wait ....