{
String siteURL = rs.getString("SITEURL");
feed.setSiteURL(siteURL == null ? null : new URL(siteURL));
} catch (MalformedURLException e)
{
throw new PersistenceException(MessageFormat.format(
Strings.error("db.currupted.site.url.for.feed"), feedId));
}
try
{
String xmlURL = rs.getString("XMLURL");
feed.setXmlURL(xmlURL == null ? null : new URL(xmlURL));
} catch (MalformedURLException e)
{
throw new PersistenceException(MessageFormat.format(
Strings.error("db.currupted.xml.url.for.feed.0"), feedId));
}
feed.setBaseTitle(rs.getString("TITLE"));
feed.setBaseAuthor(rs.getString("AUTHOR"));
feed.setBaseDescription(rs.getString("DESCRIPTION"));
feed.setCustomTitle(rs.getString("CUSTOMTITLE"));
feed.setCustomAuthor(rs.getString("CUSTOMAUTHOR"));
feed.setCustomDescription(rs.getString("CUSTOMDESCRIPTION"));
feed.setDead(rs.getBoolean("DEAD"));
feed.setInLinks(rs.getInt("INLINKS"));
feed.setLastMetaDataUpdateTime(rs.getLong("LASTMETADATAUPDATETIME"));
feed.setUserTags(StringUtils.keywordsToArray(rs.getString("USERTAGS")));
feed.setUnsavedUserTags(rs.getBoolean("UNSAVEDUSERTAGS"));
feed.setTagsDescription(rs.getString("TAGSDESCRIPTION"));
feed.setTagsExtended(rs.getString("TAGSEXTENDED"));
feed.setDisabled(rs.getBoolean("DISABLED"));
feed.setSyncHash(rs.getInt("SYNC_HASH"));
} else
{
throw new PersistenceException(MessageFormat.format(
Strings.error("db.feed.was.not.found.in.directfeeds.table"), feedId));
}
} finally
{
rs.close();