more support for labels

This commit is contained in:
sebd 2005-05-20 14:15:18 +00:00
parent f44c7aa2df
commit 3823e65134
1 changed files with 3 additions and 0 deletions

View File

@ -205,10 +205,13 @@ class DbXmlContainerHolder(dataholders.DataHolder):
uriBase = self.getUriAbsolutePath()
names = {}
results = self.getResultFetchedFromXpath(xpathExpression)
labelValue = dbxml.XmlValue("")
for value in results:
document = value.asDocument()
name = document.getName()
uri = "%s/%s" % (uriBase, name)
if document.getMetaData("http://www.sleepycat.com/2002/dbxml", "label", labelValue):
name = labelValue.asString()
names[uri] = name
return names