Groovy
Retrieve the first object (index [0]) among all objects attached to this page and class XWikiComments
com.xpn.xwiki.api.Object@2974feea
Retrieve all objects attached to this page and of class XWikiComments
[com.xpn.xwiki.api.Object@2bf79fd7, com.xpn.xwiki.api.Object@e1ef2ce, com.xpn.xwiki.api.Object@11d6b9a0, com.xpn.xwiki.api.Object@2834c086, com.xpn.xwiki.api.Object@1f4bb209, com.xpn.xwiki.api.Object@22957cec, com.xpn.xwiki.api.Object@43c7bb1, com.xpn.xwiki.api.Object@1edca3a3, com.xpn.xwiki.api.Object@277b3229]
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