Kamna Jain wrote:
> On the same note, I also have the following questions: The answers will help
> implement whichever option we choose:
> 
> 1) Is there a limit on the number of members that can belong to a group?

No. Well, there's the practical limit of how large Java lists can get 
and how much memory the JVM has, but there's no special limit set in the 
XWiki core.

> 2) How can I create a "global" hashmap (xwiki.getHashMap()) that can be
> referenced anywhere (any page/space) to retrieve values based on keys?

You can't. That's what the XWiki objects are for, to give you 
persistence. Theoretically you can create a HashMap and put it in the 
application context, but that will disappear when you restart the 
server, and it requires programming rights.

> 3) Can I use the $context to add some more values(needed for our project) to
> the hashtable?

Yes; note that it requires programming rights.

> 4)  I came across the following code snippet int he Wiki editor of the
> PanelWizard:
> #set($categoryMap = $xwiki.getHashMap())
> #foreach($category in $categoryList)
>   $!categoryMap.put($category, $xwiki.getArrayList())
> #end
> 
> I do not understand the use of "!" in the put() method. what do we achieve
> with this!

Standard Velocity syntax, it means that a null output will not print the 
code. By default, when some script doesn't return a string, it will be 
printed literally, and ! prohibits this. If it wouldn't be there, the 
rendered page would literally display several $categoryMap.put... texts.
-- 
Sergiu Dumitriu
http://purl.org/net/sergiu/
_______________________________________________
users mailing list
[email protected]
http://lists.xwiki.org/mailman/listinfo/users

Reply via email to