*/
public MarkupElement nextTag() throws ParseException
{
// Get the next tag from the markup.
// If null, no more tags are available
XmlTag xmlTag = (XmlTag)getParent().nextTag();
if (xmlTag == null)
{
return xmlTag;
}
final String namespace = markup.getWicketNamespace();
// Identify tags with Wicket namespace
ComponentTag tag;
if (namespace.equalsIgnoreCase(xmlTag.getNamespace()))
{
// It is <wicket:...>
tag = new WicketTag(xmlTag);
// Make it a Wicket component. Otherwise it would be RawMarkup
tag.setId("_" + tag.getName());
tag.setAutoComponentTag(true);
tag.setModified(true);
// If the tag is not a well-known wicket namespace tag
if (!isWellKnown(xmlTag))
{
// give up
throw new ParseException("Unknown tag name with Wicket namespace: '" +
xmlTag.getName() +
"'. Might be you haven't installed the appropriate resolver?", tag.getPos());
}
}
else
{