How to develop mix plug-ins
[back]
Note that this Tutorial is a stub and only provides basic information.
In this tutorial we assume you have already setup a development environment (see this tutorial on how to setup a development environment).
The plug-ins are located in the package plugins and are sorted by layers (e.g. package plugins.layer1network for network layer plug-ins.). Each plug-in contains classes for both clients (ClientPlugIn.java) and mixes (MixPlugIn.java) in a package with the name of the plug-in (e.g. plugins.layer1network.cascade_TCP_v0_001). The plug-in package will also contain a config file (PlugInSettings.txt) with the settings for the plug-in. You can use settings.getProperty() in your classes to access these settings.
To develop your own plug-ins we suggest you have a look at a few very simple example plug-ins that will give an overview of the required interfaces etc. The no_delay_v0_001 plug-ins on layer 2 and 3 are very easy to understand and can be extended with specific code.
To test your plug-ins you will have to select them in ./inputOutput/anonNode/pluginComposition/defaultComposition.txt (Make sure the property key PLUG_IN_COMPOSITION in ./inputOutput/anonNode/generalConfig.txt is set to defaultComposition.txt).
Please have a look at the plug-ins already implemented before starting to write a new one. If no suiting plug-in is available you may still want to extend a plugin instead of writing a new one completely from scratch.