I have the following code in one of my pages and it does what I am expecting
however I'd like to try and generalize it some.

#set ($hql = ", BaseObject as obj where obj.name = doc.fullName and
obj.className = 'CPA_FAQs.FAQClass' and doc.space='MySpace'")
#set($recentDocs = $xwiki.searchDocuments($hql, 5, 0))
#if($recentDocs.size() > 0)
  #foreach($entry in $recentDocs)
    #set($faqDoc = $xwiki.getDocument('MySpace', $entry)) 

In this example is $entry an instance of com.xpn.xwiki.api.Object? If so, is
there a way to get the space from it without doing
$xwiki.getDocument('MySpace', $entry)? I would like to generalize that
statement so I can re-use the code for any documents in any space as opposed
to having to hard-code the space.

.:. Kevin
View this message in context: 
Sent from the XWiki- Users mailing list archive at Nabble.com.

users mailing list

Reply via email to