Search in sources :

Example 1 with FactoryTag

use of org.cerberus.crud.factory.impl.FactoryTag in project cerberus-source by cerberustesting.

the class TagDAO method loadFromResultSet.

@Override
public Tag loadFromResultSet(ResultSet rs) throws SQLException {
    long id = ParameterParserUtil.parseLongParam(rs.getString("tag.id"), 0);
    String tag = ParameterParserUtil.parseStringParam(rs.getString("tag.tag"), "");
    String description = ParameterParserUtil.parseStringParam(rs.getString("tag.description"), "");
    String campaign = ParameterParserUtil.parseStringParam(rs.getString("tag.campaign"), "");
    Timestamp dateEndQueue = rs.getTimestamp("tag.DateEndQueue");
    String usrModif = ParameterParserUtil.parseStringParam(rs.getString("tag.UsrModif"), "");
    String usrCreated = ParameterParserUtil.parseStringParam(rs.getString("tag.UsrCreated"), "");
    Timestamp dateModif = rs.getTimestamp("tag.DateModif");
    Timestamp dateCreated = rs.getTimestamp("tag.DateCreated");
    // TODO remove when working in test with mockito and autowired
    factoryTag = new FactoryTag();
    return factoryTag.create(id, tag, description, campaign, dateEndQueue, usrCreated, dateCreated, usrModif, dateModif);
}
Also used : IFactoryTag(org.cerberus.crud.factory.IFactoryTag) FactoryTag(org.cerberus.crud.factory.impl.FactoryTag) Timestamp(java.sql.Timestamp)

Aggregations

Timestamp (java.sql.Timestamp)1 IFactoryTag (org.cerberus.crud.factory.IFactoryTag)1 FactoryTag (org.cerberus.crud.factory.impl.FactoryTag)1