This tutorial explains
how to write, load and use a VisANT plug-in. You must download
VisANT and run it locally to use/develop the plug-ins. You will also
want to check out the VisANT core API documentation.
Installation & Getting Started
Download VisAnt.jar and put it in a
directory, say visant. Under
directory visant, create a sub-directory named plugins.
When VisANT starts as a local application, it will always check out
all .jar files in the plugins directory and try to load all
available plug-ins. This is the convenient way for most VisANT users
to install plug-ins. Of course the plug-ins can also be put in any
directory and VisANT has provided a menu named Load Plugin
from a Jar File
under the Plugins
menu in VisANT menubar, which allows the user to load plug-ins from
a jar file located in other places.
The VisANTAbstractPlugin class
VisANTAbstractPlugin is an abstract class that serves as the
starting point for any VisANT plug-in, and all plug-ins must have at
least one class extended from this abstract class. The abstract
class defines a default constructor with no parameters. It also
provides an about function to let the developer introduce the
functionalities of the plug-in and several other methods to create a
standard menu in VisANT. VisANT will call the constructor to
instantiate the plug-in.
In general, we suggest that developers create a menu and add it to
VisANT, and overwrite the about function so the user will understand
what the plug-in for. If the about function is implemented, VisANT
will automatically create an About menu if there is a menu
associated with the plug-in. For your reference, the source code of
VisANTAbstractPlugin is provided.
Given this brief
introduction, let's start the tutorials:
Tutorial of Hello World Plug-in
Tutorials of Network Randomization
of Network Construction Plug-in
Tutorial to use
Eclipse for plugin development