jackrabbit-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Rodrigo Meza <rodrigo.meza.fo...@gmail.com>
Subject bug in Item.getPath?
Date Mon, 21 Sep 2009 06:00:55 GMT
Hi,
    I have a repository with same name siblings, like:

 myItem[1]
 myItem[2]
 myItem[3]
 myItem[4]

However, when I call getPath() on the first node defined with this name, I
obtain "myItem"  instead of "myItem[1]". Is this behaviour correct?... as
far as I know it is not, because the specification of  getPath() in
jsr170-spec says:

" Returns the absolute path to this item.
If the path includes items that are same name sibling nodes or multi-value
properties then those elements in the path will include the appropriate
“square bracket” index notation (for example, /a/b[3]/c).
A RepositoryException is thrown if an error occurs."


Am I getting something wrong from the specification? There exist other
method that returns the square bracket index notation for the first element?

Thanks,
  Rodrigo.

Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message