Skip to main content

Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Modeling » TMF (Xtext) » Visibility, scoping and imported namespace
Visibility, scoping and imported namespace [message #879591] Thu, 31 May 2012 13:40
Fabian G. is currently offline Fabian G.Friend
Messages: 60
Registered: May 2010
Location: Christchurch (NZ)
Hi All,

I'm trying to have nested visibility for my dsl model elements, as well as explicit imports of other models (when imported, referred by their simple names). I've explored this forum, the doc and the itemis blog, but couldn't achieve to have it right.

Here's a sample grammar (incomplete):

  'model' name=ID ';'

  'import' importedNamespace=[Model|FQNWithWildCard]';';



I activated these fragments to have the qualified name mechanism working.
fragment = scoping.ImportNamespacesScopingFragment {}
fragment = exporting.QualifiedNamesFragment {}

The problem is that every model in the same project is visible in all models (I filtered them by using filteringscope, but I'm not really happy with it since they're flat representation, so it causes problems in some places). I tried to extends the ImportedNamespaceAwareLocalScopeProvider, but I could not avoid importing all models. Could someone point me to the right strategy?

Previous Topic: Auto insert single proposals
Next Topic:Xtext: Xbase extensions
Goto Forum:

Current Time: Thu Dec 03 23:51:11 GMT 2020

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

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

Back to the top