Search in sources :

Example 1 with FactoryRobot

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

the class RobotDAO method loadFromResultSet.

@Override
public Robot loadFromResultSet(ResultSet rs) throws SQLException {
    Integer robotID = ParameterParserUtil.parseIntegerParam(rs.getString("robotID"), 0);
    String robot = ParameterParserUtil.parseStringParam(rs.getString("robot"), "");
    String host = ParameterParserUtil.parseStringParam(rs.getString("host"), "");
    String port = ParameterParserUtil.parseStringParam(rs.getString("port"), "");
    String platform = ParameterParserUtil.parseStringParam(rs.getString("platform"), "");
    String browser = ParameterParserUtil.parseStringParam(rs.getString("browser"), "");
    String version = ParameterParserUtil.parseStringParam(rs.getString("version"), "");
    String active = ParameterParserUtil.parseStringParam(rs.getString("active"), "");
    String description = ParameterParserUtil.parseStringParam(rs.getString("description"), "");
    String userAgent = ParameterParserUtil.parseStringParam(rs.getString("useragent"), "");
    String screenSize = ParameterParserUtil.parseStringParam(rs.getString("screensize"), "");
    String user = ParameterParserUtil.parseStringParam(rs.getString("host_user"), "");
    String password = ParameterParserUtil.parseStringParam(rs.getString("host_password"), "");
    String robotDecli = ParameterParserUtil.parseStringParam(rs.getString("robotdecli"), "");
    // TODO remove when working in test with mockito and autowired
    factoryRobot = new FactoryRobot();
    return factoryRobot.create(robotID, robot, host, port, platform, browser, version, active, description, userAgent, screenSize, user, password, robotDecli);
}
Also used : IFactoryRobot(org.cerberus.crud.factory.IFactoryRobot) FactoryRobot(org.cerberus.crud.factory.impl.FactoryRobot)

Aggregations

IFactoryRobot (org.cerberus.crud.factory.IFactoryRobot)1 FactoryRobot (org.cerberus.crud.factory.impl.FactoryRobot)1