wzr1337 / rsi.server

This project implements the Volkswagen Infotainment Web Interface as published under https://www.w3.org/Submission/2016/01/. The viwi is now called RESTful service interface (rsi)

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Plugins should have access to resources of other plugins

BenjaminDobler opened this issue · comments

I`m thinking of situations where you have a resource that contains elements which contain references to elements of other resources. How would a plugin right now get information about these resources (e.g. maybe to expand them or update them).
Maybe each plugin could get registered in some kind of plugin registry and this registry is then exposed to each plugin?

good idea.. the plugin loader might expose these information

for now I'd recommend too just "import" the needed parts

Within a service, you can now lookup resources by using getResource(name:string).

It is part of a refactoring service class

What is the desired feature scope for this?

Given that resources within a service do actually know and now can also lookup each other this already provides the ability to implement a plugin logic that for instance let's a resource modify certain other resources within the same service based on it's own current data set.

Benjamin's initial thought was going further by suggesting a mechanism to provide each service with information about all available services and thus enable an interaction between services.

Maybe it should be defined in which extend such functionality should be implemented.

Thinking about this further, this kind of relates to or could be the basis of #30 as well. Not sure about a smart solution though. I gotta dig a little deeper and understand viwi in it's current state a little better still.