This page describes how to create a custom application that is visible as an icon on the start page of the server, with a simple sample called CurrentTimePlugin.
A compiled version of the plugin is made available as application.currenttime.zip
. In order to test this plugin, you need to copy the file into the plugins folder of your installation. Afterwards the server needs to be restarted. The module will now be displayed on the start page of the server.
You can also write your own implementation of the interfaces IModule and AngularModuleHandler. This implementation should extend the classes: com.inet.remote.gui.AngularModule
and com.inet.remote.gui.angular.AngularModuleHandler
, respectively.
In the next step you write your own server plugin. It must implement the interface com.inet.plugin.ServerPlugin
and have an empty public constructor for loading. In the method registerExtension
you must register both of your classes. This can look like:
public void registerExtension( ServerPluginManager spm ) { spm.register( IModule.class, new SampleApplicationModule() ); spm.register( AngularModuleHandler.class, new SampleApplicationHandler() ); }
Please refer to the sample com.inet.application.currenttime.SampleApplicationServerPlugin
to see how this is done there.
The following steps need to be taken if changes are made to the plugin code.
The plugin.properties
and server plugin class are preconfigured to be used without modifications. If the sample is the basis for a custom plugin or just needs some adaptions, please refer to the platform programming guide for detailed instructions.
In order to build this plugin the following jar files are required at minimum:
You can copy these to the current sample directory or link them into the project of your IDE.
The plugin must be compiled into a jar file that is named like the id of the plugin. In this example it is application.currenttime.jar
. It also must contain the compiled sources as well as required language resources and images.
The target plugin is a zip file, named application.currenttime.zip
in this example. It contains the compiled jar file and the plugin.properties
which configure the custom plugin.
The provided build.gradle
in the sample can be used to build the plugin as well as any other build system.
Copy the ZIP file of the plugin into the plugins directory of the server and restart it. If there are problems, then check the log file of the server for more details. The "Config" logger is used to log plugin registration issues.