How do you communicate between eclipse declarative services and Views (ContentProviders)

后端 未结 2 837
被撕碎了的回忆
被撕碎了的回忆 2021-02-10 17:57

Say you have an eclipse plugin with various views, these views should display data from some OSGi bundle that pushes data to the Views. Rather than have every view communicate

相关标签:
2条回答
  • 2021-02-10 18:46

    you could also use Spring DM to wire up your OSGi services and use Martin Lippert glue plugin to wire up the views with OSGi Services (or Spring beans), the good bit with it is that you don't need to write any code based on the service API or spring API...

    0 讨论(0)
  • 2021-02-10 19:02

    One solution is to use a Singleton, and have one, or both, of the Application and Facade register with that Singleton.

    However, I really don't like the idea of throwing a global variable at this problem. It doesn't seem to make sense -- this must be a common problem, so I'm assuming there is an elegant solution and I just don't know how to search for it.

    0 讨论(0)
提交回复
热议问题