Thanks Vincent & Asiri! That did the trick! This is a really powerful feature (don't think any other wiki supports something this dynamic)! Please keep up the great work on XWiki!!! -- Lewis On Tue, Sep 29, 2009 at 1:46 AM, Vincent Massol <[email protected]> wrote:
On Sep 28, 2009, at 6:46 PM, Vincent Massol wrote:
On Sep 28, 2009, at 6:34 PM, Lewis Denizen wrote:
Hi xwiki-users,
I've been playing with this new Wiki Macros stuff (this stuff is superb!), but I've got one question. In a conventional 2.0 Java Macro, I can inject things like DAOs and AccessBridges (like DocumentAccessBridge). Is this possible using the new Wiki Macros (for example, how can I inject a DocumentAccessBridge into a Groovy class defined within the Wiki Macro? Is there a static ComponentManager that can perform lookups())?
Yes, for now you can use: Utils.getComponent(TheComponentClass.class) or Utils.getComponent(TheComponentClass.class, String hint)
Forgot to mention you'll need to import:
import com.xpn.xwiki.web.*
-Vincent
-Vincent
Again, great great great work with XWiki 2.0!
-- Lewis
_______________________________________________ users mailing list [email protected] http://lists.xwiki.org/mailman/listinfo/users