Skip to main content

Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Modeling » TMF (Xtext) » customise plugin.xml
customise plugin.xml [message #1745460] Tue, 11 October 2016 08:24 Go to next message
herve giraud is currently offline herve giraudFriend
Messages: 6
Registered: February 2016
Junior Member
I'm creating an idea plugin, and I want to customise the oultine.
I found that instruction in plugin_gen.xml :

How do I instruct the plugin to use my own implementation (something like MyLanguageStructureViewFactory) instead of com.intellij.lang.PsiStructureViewFactory ?

Is there another way to create a custom outline view in idea ?

Re: customise plugin.xml [message #1746033 is a reply to message #1745460] Thu, 20 October 2016 16:32 Go to previous message
Jan Koehnlein is currently offline Jan KoehnleinFriend
Messages: 760
Registered: July 2009
Location: Hamburg
Senior Member
Xtext uses dependency injection to set up the infrastructure of your language.
The MyLanguageExtensionFactory makes sure that the injector is used to create an instance of the implementationClass at runtime.

In order to get your implementation in, you have to extend PsiStructureViewFactory, and bind your implementation to the class PsiStructureViewFactory in the MyLanguageIdeaModule, e.g. by adding

Class<? extends PsiStructureViewFactory> bindPsiStructureViewFactory() {
return MyLanguageStructureViewFactory

See also the Xtext documentation on dependency injection.

Get professional support from the Xtext committers at
Previous Topic:Cross Referencing an already crossreferenced element in xtext doesn't work
Next Topic:Help with Generate Infrastructure MWE - create generator package
Goto Forum:

Current Time: Sun Jun 04 23:15:39 GMT 2023

Powered by FUDForum. Page generated in 0.02303 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top