String name = attrs.getValue("name");
Log log = getLog();
if (log.isTraceEnabled())
log.trace(_loc.get("parse-sqlrsmapping", name));
MappingRepository repos = (MappingRepository) getRepository();
QueryResultMapping result = repos.getCachedQueryResultMapping
(null, name);
if (result != null && log.isWarnEnabled())
log.warn(_loc.get("override-sqlrsmapping", name,
currentLocation()));
result = repos.addQueryResultMapping(null, name);
result.setListingIndex(_resultIdx++);
addComments(result);
Object cur = currentElement();
Object scope = (cur instanceof ClassMetaData)