}
void parseStartElement( )
throws ThreddsXmlParserException
{
StartElement startElement = this.getNextEventIfStartElementIsMine();
Attribute nameAtt = startElement.getAttributeByName( CatalogElementNames.CatalogElement_Name );
String nameString = nameAtt != null ? nameAtt.getValue() : null ;
Attribute versionAtt = startElement.getAttributeByName( CatalogElementNames.CatalogElement_Version );
String versionString = versionAtt != null ? versionAtt.getValue() : null;
Attribute expiresAtt = startElement.getAttributeByName( CatalogElementNames.CatalogElement_Expires );
String expiresString = expiresAtt != null ? expiresAtt.getValue() : null;
DateType expires = null;
try {
expires = expiresString != null ? new DateType( expiresString, null, null ) : null;
}
catch ( ParseException e )
{
String msg = "Failed to parse catalog expires date [" + expiresString + "].";
ThreddsXmlParserIssue issue = StaxThreddsXmlParserUtils.createIssueForException( msg, this.reader, e );
log.warn( "parseStartElement(): " + issue.getMessage(), e );
// ToDo Gather issues rather than throw exception.
throw new ThreddsXmlParserException( issue );
}
Attribute lastModifiedAtt = startElement.getAttributeByName( CatalogElementNames.CatalogElement_LastModified );
String lastModifiedString = lastModifiedAtt != null ? lastModifiedAtt.getValue() : null;
DateType lastModified = null;
try {
lastModified = lastModifiedString != null ? new DateType( lastModifiedString, null, null ) : null;
}