jgrapht / jgrapht Public
forked from lingeringsocket/jgraphtUsers: Running JGraphT demos
Pages 66
- Home
- Adopt a highway
- Demos
- Dev guide
- Become a Contributor
- Coding and Style Conventions
- Contributor Guidelines
- Deprecation policy
- How to add example code
- How to make your first (code) contribution
- How to setup your development environment for JGraphT
- How to write documentation
- Maven Plugin Installation Guide
- Open tasks, projects and collaboration ideas
- Unit testing
- Website Deployment
- Writing new wiki pages
- GSoC
- Users
Clone this wiki locally
JGraphT has a demo package org.jgrapht.demo
which includes small demo applications. These classes provide a good starting point to learn how to work with JGraphT. Moreover, all classes come with corresponding test classes. These test classes provide a valuable source of usage examples (see the source code of your desired JGraphT release).
To run the graph visualization demo from the downloaded release, try executing this command in the lib directory:
java -jar jgrapht-demo-x.y.z.jar
To run a different demo class, use:
java -cp jgrapht-demo-x.y.z.jar org.jgrapht.demo.<DemoName>
For instance:
java -cp jgrapht-demo-1.1.0.jar org.jgrapht.demo.CompleteGraphDemo
If you want more control over the demos, e.g. you want to play around and make modifications, it is recommended that you first download the source code of your desired version, or, alternatively, download the master branch. Next, follow the instructions for your specific IDE (skip the instructions pertaining the Java formatting rules and imports styles):
For the full list of demos available, see the demo package.
.