!tag.isAutoComponentTag())
{
Iterator<ComponentTag> componentTagIterator = enclosures.descendingIterator();
while (componentTagIterator.hasNext())
{
ComponentTag lastEnclosure = componentTagIterator.next();
String attr = getAttribute(lastEnclosure, null);
if (Strings.isEmpty(attr) == true)
{
lastEnclosure.getAttributes().put(getInlineEnclosureAttributeName(null),
tag.getId());
lastEnclosure.setModified(true);
}
}
}
else if (tag.isClose() && tag.closes(enclosures.peek()))
{
ComponentTag lastEnclosure = enclosures.pop();
String attr = getAttribute(lastEnclosure, null);
if (Strings.isEmpty(attr) == true)
{
throw new ParseException("Did not find any child for InlineEnclosure. Tag:" +
lastEnclosure.toString(), tag.getPos());
}
}
}
return tag;