no message

This commit is contained in:
2024-10-22 13:36:57 +03:00
parent fc6282cd22
commit 54a52a1e6e
15 changed files with 170 additions and 174 deletions

View File

@@ -3,14 +3,13 @@ import Common.Utils.Utils_;
import _VisualDVM.Global;
import _VisualDVM.Passes.Server.ComponentsRepositoryPass;
import _VisualDVM.Repository.BugReport.BugReport;
import _VisualDVM.Repository.BugReport.UI.BugReportInterface;
import _VisualDVM.Repository.Server.ServerCode;
import _VisualDVM.Repository.Server.ServerExchangeUnit_2021;
public class DownloadBugReport extends ComponentsRepositoryPass<BugReport> {
@Override
protected boolean canStart(Object... args) {
target = (BugReport) args[0];
return !BugReportInterface.getArchiveFile(target).exists();
return !target.getArchiveFile().exists();
}
@Override
protected void performPreparation() throws Exception {
@@ -19,10 +18,10 @@ public class DownloadBugReport extends ComponentsRepositoryPass<BugReport> {
@Override
protected void ServerAction() throws Exception {
Command(new ServerExchangeUnit_2021(ServerCode.ReceiveBugReport, target.id));
Utils_.bytesToFile((byte[]) response.object, BugReportInterface.getArchiveFile(target));
Utils_.bytesToFile((byte[]) response.object, target.getArchiveFile());
}
@Override
protected boolean validate() {
return BugReportInterface.getArchiveFile(target).exists();
return target.getArchiveFile().exists();
}
}