Groovy
Retrieve the first object (index [0]) among all objects attached to this page and class XWikiComments
com.xpn.xwiki.api.Object@59de78f3
Retrieve all objects attached to this page and of class XWikiComments
[com.xpn.xwiki.api.Object@32fe11fd, com.xpn.xwiki.api.Object@464f1332, com.xpn.xwiki.api.Object@71755bad, com.xpn.xwiki.api.Object@4fd5f50c, com.xpn.xwiki.api.Object@67cb0fc6, com.xpn.xwiki.api.Object@4478c566, com.xpn.xwiki.api.Object@54e7cea8, com.xpn.xwiki.api.Object@3eb0a324, com.xpn.xwiki.api.Object@3ea6b0a3]
Retrieve the author property of all objects attached to this page and of class XWikiComments
println objsAuthors
[XWiki.RicardoRodriguezFernandez, XWiki.RicardoRodriguezFernandez, XWiki.RicardoRodriguezFernandez, XWiki.RicardoRodriguezFernandez, XWiki.IsabelListaGarcia, Anonymous, XWiki.YolandaMariaListeMartinez, XWiki.RicardoRodriguezFernandez, XWiki.RicardoRodriguezFernandez]
objsAuthor = doc.getObjects('XWiki.XWikiComments')[2].author
println objs[0].author