Recommend this page to a friend! |
Download .zip |
Info | Screenshots | View files (6) | Download .zip | Reputation | Support forum (5) | Blog | Links |
Last Updated | Ratings | Unique User Downloads | Download Rankings | |||||
2011-02-04 (5 years ago) | 75% | Total: 1,073 This week: 1 | All time: 3,349 This week: 1,047 |
Version | License | PHP version | Categories | |||
code-graph 0.1 | BSD License | 4 | Utilities and Tools, Language |
Description | Author | |||
This packages can be used to generate call graphs of PHP code with GraphViz. Innovation Award
|
Codegraph requires the Graphviz package (which does the *really* clever stuff). Codegraph ppackages are available from various places, or you can download the source at: http://www.graphviz.org/ This is the second release version which has a much cleaner API. To see what it does checkout the key.jpeg and self.jpeg files (the latter is the result of running the code on itself). The example scripts expects a writable directory called 'graphs' in the same dir. The dotwriter.inc.php defines 2 classes and some supporting functions. It should come with this readme.txt file and 3 example scripts. * example1.php provides a user to upload a PHP src file and returns the resulting jpeg image * example2.php This was front end which shiped with the first verion - and allows you to try out the different options for the graph generator * example3.php This script defines a callback handler which adds URLs to the nodes rendered in the image - maaking them clickable. It is configured to geerate links to PHPXREF documentation. It has been written for Unix/Linux systems but would not require l ot of changes to support MSWindows: I believe the only change necessary is to specify the location of the graphViz dot interpreter. This is currently hard-coded as /usr/bin/dot. However the value can be overridden at run time between instantiating the dotrunner class and generating the output file, e.g. $c = new dotrunner(); $c->graphVizBin='/windows/cygwin/usr/bin/dot.exe'; $c->outputFileName=tempnam('graphs/','graph'); $c->genGraph(.... To see what it does checkout the key.jpeg and self.jpeg files (the latter is the result of running the code on itself). The script expects a writable directory called 'graphs' in the same dir. Note the 'cleanUp()' method defined in the class deletes the graphViz input file but not the output file(s). You should plan to make some provision for these in your own code. |
Screenshots | ||
Files |
File | Role | Description |
---|---|---|
dotwriter.inc.php | Class | includeable parser/generator |
example1.php | Example | Usage example |
example2.php | Example | Usage example |
example3.php | Example | Usage example |
parse_gen.php | Example | source code and front end |
README | Doc. | instructions |
Version Control | Unique User Downloads | Download Rankings | |||||||||||||||
0% |
|
|
User Ratings | User Comments (2) | |||||||||||||||||||||||||||||||||||||
|
|
Applications that use this package |
If you know an application of this package, send a message to the author to add a link here.