Hi Maxime,

On Feb 15, 2011, at 12:30 PM, Maxime Sinclair wrote:

> Hello,
> 
> What is the best way to create a configurable macro ?

Wiki macro or java macro?

For java macro: you can use the xwiki-configuration module. Check the Velocity 
macro for example, and more specifically the VelocityMacroConfiguration class 
and its implementation (DefaultVelocityMacroConfiguration).

For wiki macros, I haven't thought much about it and it depends if they use 
velocity only or groovy. But the idea is to do the same.

More info here:
http://extensions.xwiki.org/xwiki/bin/view/Extension/Configuration+Module

Thanks
-Vincent

> For example, a macro uses an external resource (like the address of a
> server). The administrator of the wiki must configure this resource
> during the installation of the macro (just after the import). Of
> course, he can update the source code of the macro but it is not very
> user friendly.
> 
> Do you have any suggestions ? Thank for your help.
> 
> Maxime Sinclair
_______________________________________________
users mailing list
[email protected]
http://lists.xwiki.org/mailman/listinfo/users

Reply via email to