type = ContentType.XHTML;
}
else
{
log.error("Unable to parse extract type in " + getQualifiedName() );
SwordValidationInfo info = new SwordValidationInfo(xmlName,
new XmlName(attribute),
"Invalid content type has been specified",
SwordValidationInfoType.ERROR);
info.setContentDescription(value);
attributeItems.add(info);
success = false;
}
if( success )
{
SwordValidationInfo info = new SwordValidationInfo(xmlName, new XmlName(attribute));
info.setContentDescription(type.toString());
attributeItems.add(info);
}
}
else
{
SwordValidationInfo info = new SwordValidationInfo(xmlName,
new XmlName(attribute),
SwordValidationInfo.UNKNOWN_ATTRIBUTE,
SwordValidationInfoType.INFO);
info.setContentDescription(attribute.getValue());
attributeItems.add(info);
}
}
// retrieve all of the sub-elements
int length = text.getChildCount();
if( length > 0 )
{
content = unmarshallString(text);
}
}
catch( Exception ex )
{
log.error("Unable to parse an element in " + getQualifiedName() + ": " + ex.getMessage());
throw new UnmarshallException("Unable to parse an element in " + getQualifiedName(), ex);
}
SwordValidationInfo result = null;
if( validationProperties != null )
{
result = validate(validationItems, attributeItems, validationProperties);
}
return result;