[josm-dev] WMS and remote-control

Sebastian Klein bastikln at googlemail.com
Sun Aug 22 11:26:18 BST 2010


Stephan Knauss wrote:
> Sebastian Klein wrote:
>> So either the common protocol must be included in Josm core or
>> another possible solution would be to use reflection.
> 
> How about adding the basic functionality into core? Providing the 
> listener and accepting commands.
> 
> By default it will have no commands included.
> 
> It provides a capabilities command that reports back the supported 
> commands and their protocol version.
> 
> Plugins can register new commands with the core similar than they would 
> register other functionality (like shortcuts and such).
> 
> So the core will know what commands are available and which plugin 
> handles them.
> It can also reject registrations of commands that already exist. It can 
> provide a single configuration dialog where the plugins can append their 
> plugin-specific settings.
> 
> Comments?

I consider this is a viable solution. It fixes the problem of version 
dependency between wmsplugin and remotecontrol. The core part of 
remotecontrol would go into JOSM main, but it would not even listen to 
some network port, if no commands are registered. (This should satisfy 
the paranoid people.)

remotecontrol plugin would then provide a basic set of commands and 
register them with JOSM core.

Each time the protocol of the callback changes, developers have to 
update the "Mainversion" of all the "remote-controlling" plugins. 
(currently wmsplugin and remotecontrol)

This would fit much better in the current framework.


Sebastian



More information about the josm-dev mailing list