niagara-ax/modules/cfr_output/com/tridium/sys/transfer/IntraFileSpaceMove.java
2026-03-17 13:31:18 -07:00

46 lines
1.6 KiB
Java

/*
* Decompiled with CFR 0.152.
*/
package com.tridium.sys.transfer;
import com.tridium.sys.transfer.FileToFile;
import com.tridium.sys.transfer.TransferResult;
import javax.baja.file.BFileSpace;
import javax.baja.file.BIFile;
import javax.baja.file.FilePath;
public class IntraFileSpaceMove
extends FileToFile {
public TransferResult transfer() throws Exception {
this.init();
this.name();
this.move();
return null;
}
public void move() throws Exception {
if (IntraFileSpaceMove.isDebugOn()) {
IntraFileSpaceMove.debug("IntraFileSpaceMove.move");
}
BFileSpace bFileSpace = this.targetDir.getFileSpace();
FilePath filePath = this.targetDir.getFilePath();
int n = 0;
while (n < this.sourceFiles.length) {
BIFile bIFile = this.sourceFiles[n];
FilePath filePath2 = bIFile.getFilePath();
FilePath filePath3 = filePath.merge(this.insertNames[n]);
if (IntraFileSpaceMove.isDebugOn()) {
IntraFileSpaceMove.debug(" " + filePath2 + " -> " + filePath3);
}
if (this.targetDir.toString(null).equals("file:!trash ") || this.targetDir.toString(null).startsWith("file:!trash/")) {
this.updateStatus(this.lexDeleting + " \"" + filePath2.getName() + "\"...");
} else {
this.updateStatus(this.lexMoving + " \"" + filePath2.getName() + "\"...");
}
bFileSpace.move(filePath2, filePath3, this.getContext());
++n;
}
}
}