Column[] columns = { CfbSchema.CLASSNAME, CfbSchema.METHODNAME, CfbSchema.METHODROLE, CfbSchema.STARTLINE, CfbSchema.ENDLINE };
Table[] tables = { CfbSchema.LOCATIONS };
Condition[] conditions = { new Condition(CfbSchema.LOCID, locId, Operation.EQUAL) };
Column[] columns = { CfbSchema.CLASSNAME, CfbSchema.METHODNAME, CfbSchema.METHODROLE, CfbSchema.STARTLINE, CfbSchema.ENDLINE };
Table[] tables = { CfbSchema.LOCATIONS };
Condition[] conditions = { new Condition(CfbSchema.LOCID, locId, Operation.EQUAL) };
String className = row.getString(0);
String methodName = row.getString(1);
String methodRole = row.getString(2);
String className = row.getString(0);
String methodName = row.getString(1);
String methodRole = row.getString(2);
Location loc = new Location(locId, className, methodName, methodRole, startLine, endLine);
return loc;
Location loc = new Location(locId, className, methodName, methodRole, startLine, endLine);
return loc;
Column[] columns = { CfbSchema.NAME, CfbSchema.VARROLE };
Table[] tables = { CfbSchema.VARIABLES };
Condition[] conditions = { new Condition(CfbSchema.VARID_PK, varId, Operation.EQUAL) };
Column[] columns = { CfbSchema.NAME, CfbSchema.VARROLE };
Table[] tables = { CfbSchema.VARIABLES };
Condition[] conditions = { new Condition(CfbSchema.VARID_PK, varId, Operation.EQUAL) };
- Condition[] conditions = { new Condition( CfbSchema.STARTTIME, analysis.getStart(), Operation.LESS_THAN ) };
+ Condition[] conditions = {
+ new Condition( CfbSchema.PROJNAME, analysis.getProjectName(), Operation.EQUAL ),
+ new Condition( CfbSchema.STARTTIME, analysis.getStart(), Operation.LESS_THAN )
+ };
- Column[] columns = { CfbSchema.VERSION, CfbSchema.STARTTIME, CfbSchema.ENDTIME };
+ Column[] columns = { CfbSchema.PROJNAME, CfbSchema.VERSION, CfbSchema.STARTTIME, CfbSchema.ENDTIME };
List<Row> rows = m_driver.select(m_con, columns, tables, conditions);
if (rows.size() < 1) {
List<Row> rows = m_driver.select(m_con, columns, tables, conditions);
if (rows.size() < 1) {
- String version = row.getString(0);
- java.util.Date start= row.getDate(1);
- java.util.Date end = row.getDate(2);
+ String projName = row.getString(0);
+ String version = row.getString(1);
+ java.util.Date start= row.getDate(2);
+ java.util.Date end = row.getDate(3);
- Analysis prior = new Analysis(version);
- prior.setId(priorId.longValue());
+ Analysis prior = new Analysis(projName, version);
+ prior.setId(analysisId.longValue());
- long bugId = row.getLong(1);
- long categoryId = row.getLong(2);
- long firstLocId = row.getLong(3);
- long secondLocId = row.getLong(4);
- long thirdLocId = row.getLong(5);
- long varId = row.getLong(6);
+ Long bugId = row.getLong(1);
+ Long categoryId = row.getLong(2);
+ Long firstLocId = row.getLong(3);
+ Long secondLocId = row.getLong(4);
+ Long thirdLocId = row.getLong(5);
+ Long varId = row.getLong(6);
String bugType = getBugType(bugId);
String category = getCategoryName(categoryId);
Location[] locations = { getLoc(firstLocId), getLoc(secondLocId), getLoc(thirdLocId) };
String bugType = getBugType(bugId);
String category = getCategoryName(categoryId);
Location[] locations = { getLoc(firstLocId), getLoc(secondLocId), getLoc(thirdLocId) };
BugInstance bug = new BugInstance(bugId, category, bugType, locations, vars);
BugInstance bug = new BugInstance(bugId, category, bugType, locations, vars);