use of com.cubrid.cubridmanager.core.logs.task.GetCasLogTopResultTask in project cubrid-manager by CUBRID.
the class SqlLogAnalyzeResultDialog method connect.
/**
* each page of log connect
*
* @param qindex String
* @param queryString StringBuffer
* @return queryString
*/
public StringBuilder connect(String qindex, StringBuilder queryString) {
final GetCasLogTopResultTask task = new GetCasLogTopResultTask(node.getServer().getServerInfo());
task.setFileName(resultFile);
task.setQindex(qindex);
TaskExecutor taskExecutor = new CommonTaskExec(Messages.loadLogTaskName);
taskExecutor.addTask(task);
new ExecTaskWithProgress(taskExecutor).exec();
if (taskExecutor.isSuccess() && task.getAnalyzeCasLogTopResultList() != null) {
AnalyzeCasLogTopResultInfo resultInfo = (AnalyzeCasLogTopResultInfo) task.getAnalyzeCasLogTopResultList();
if (resultInfo != null && resultInfo.getLogString() != null) {
for (String logString : resultInfo.getLogString()) {
queryString.append(logString + "\n");
}
}
}
return queryString;
}
Aggregations