Modify

Opened 8 years ago

Closed 7 years ago

#15218 closed enhancement (othersoftware)

Dynamic plugin classloading

Reported by: bagage Owned by: Gubaer
Priority: normal Milestone:
Component: Plugin scripting Version: latest
Keywords: github Cc:

Description

I developed a JS script to use with JOSM scripting plugin (https://github.com/Gubaer/josm-scripting-plugin) to automate some mouse movements&clicks.
Ultimately the script would invoke some other plugin (here, Todo), so that the list of todo items get filled.
However this does not work anymore since #14901 landed, since each plugin classloader is separated from each other (which is good).

My question/concern is about how one plugin can talk with another one dynamically now? Is it possible at all? One workaround would be to "communicate" via UI clicks simulation instead but maybe there's a solution here.

Attachments (0)

Change History (4)

comment:1 by Don-vip, 8 years ago

Summary: How to access another plugin classes since #14901 landed?Dynamic plugin classloading
Type: defectenhancement
  1. Core could offer an API to allow this mechanism
  2. Plugin scripting should then use this API

comment:2 by anonymous, 8 years ago

Thanks Don-vip;
Not sure how much this is an issue though - for me it's not a big deal, so no need to do it if I'm the only one affected. I think before starting working on that we should see if others have the issue as well.

comment:3 by Don-vip, 8 years ago

Component: CorePlugin scripting
Owner: changed from team to Gubaer

In fact the API already exists since r12867, see PluginClassLoader.addDependency(PluginClassLoader dependency).

It's up to scripting plugin to dynamically add dependencies to its own classloader when a script requires a new one.

comment:4 by Don-vip, 7 years ago

Keywords: github added
Resolution: othersoftware
Status: newclosed

Modify Ticket

Change Properties
Set your email in Preferences
Action
as closed The owner will remain Gubaer.
as The resolution will be set.
The resolution will be deleted. Next status will be 'reopened'.

Add Comment


E-mail address and name can be saved in the Preferences .
 
Note: See TracTickets for help on using tickets.