Subversion Repositories XServices

Compare Revisions

Ignore whitespace Rev 42 → Rev 151

/sbm4mylyn/trunk/src/net/brutex/mylyn/sbmconnector/core/SBMClient.java
47,6 → 47,11
import net.brutex.sbm.wsclient.NameValue;
import net.brutex.sbm.wsclient.Note;
import net.brutex.sbm.wsclient.ObjectFactory;
import net.brutex.sbm.wsclient.ReportCategory;
import net.brutex.sbm.wsclient.ReportInfo;
import net.brutex.sbm.wsclient.ReportResult;
import net.brutex.sbm.wsclient.ReportsFilter;
import net.brutex.sbm.wsclient.RunReportResult;
import net.brutex.sbm.wsclient.TTItem;
import net.brutex.sbm.wsclient.TableData;
import net.brutex.sbm.wsclient.TableType;
139,6 → 144,41
return list;
}
public List<TTItem> getTTItemsByReport(String reportuuid) throws CoreException {
List<TTItem> list = new ArrayList<TTItem>();
try {
RunReportResult result = port.runReport(
getAuth(), of.createQueryRange(), reportuuid, null, null, null, null, null, null,
null, null, null, null, null);
List<ReportResult> resultlist = result.getResult();
for(ReportResult r : resultlist) {
list.add(port.getItem( getAuth(), r.getItemId().getValue(), null));
}
} catch (AEWebservicesFaultFault e) {
throw new CoreException(
RepositoryStatus.createInternalError(
SBMConnectorPlugin.PLUGIN_ID, e.getMessage(), e));
}
return list;
}
public List<ReportInfo> getReportList(String solutionname) throws CoreException {
ReportsFilter filter = of.createReportsFilter();
List<ReportInfo> reportlist = new ArrayList<ReportInfo>();
filter.setSolutionName(of.createSolutionDataName(solutionname));
filter.setReportCategory(ReportCategory.USERREPORTS); //Limit this for now, because we execute by uuid only
try {
reportlist = port.getReports(getAuth(), null, filter).getReport();
} catch (AEWebservicesFaultFault e) {
throw new CoreException(
RepositoryStatus.createInternalError(
SBMConnectorPlugin.PLUGIN_ID, e.getMessage(), e));
}
return reportlist;
}
public List<String> getResultCount(String tablename, String sql) throws CoreException {
List<TTItem> list = new ArrayList<TTItem>();
List<String> idlist = new ArrayList<String>();