Java Mailing List Archive

http://www.gg3721.com/

Home » eclipse-plugin-dev.groovy »

[groovy-eclipse-plugin-dev] Accessing GroovyCompilationUnit from DSLD

Kohsuke Kawaguchi

2011-05-17

Replies: Find Java Web Hosting

Author LoginPost Reply
I'm trying to write a DSL descriptor that needs to access the
GroovyCompilationUnit that represents the source file in which the
completion is provided.
(my completion is context sensitive to the relative path of the script
from within the source root --- I want to figure out the equivalent of
the package name, even though the Groovy script files need not have
the package declaration.)

Can anyone tell me how I can obtain a reference to it from within the
contribution closure?

On a related note, I'm looking at
DSLContributionGroup.getContributions(), and I noticed that it doesn't
expose GroovyDSLDContext itself to the contribution closure. Is there
a reason it doens't do this? GroovyDSLDContext object exposes a lot of
useful information that I think would benefit the contribution
closures.

--
Kohsuke Kawaguchi                 http://kohsuke.org/

---------------------------------------------------------------------
To unsubscribe from this list, please visit:

  http://xircles.codehaus.org/manage_email


©2008 gg3721.com - Jax Systems, LLC, U.S.A.