ログ追加

This commit is contained in:
r-ca 2023-12-25 15:00:14 +09:00
parent 9534e36a9d
commit 3affd2dd2f
No known key found for this signature in database
GPG Key ID: 6A72911AC73464A9

View File

@ -36,12 +36,16 @@ public class DocumentProcessorImpl implements DocumentProcessor{
@Override @Override
public void addNewPageToLast(Bitmap bitmap) { public void addNewPageToLast(Bitmap bitmap) {
logger.debug("addNewPageToLast", "called");
Path path = documentDetail.getPath().getFullPath(); Path path = documentDetail.getPath().getFullPath();
String fileName = String.format(UUID.randomUUID().toString() + ".png"); // TODO-rca: 対応表をもたせる String fileName = String.format(UUID.randomUUID().toString() + ".png"); // TODO-rca: 対応表をもたせる
logger.debug("addNewPageToLast", "fileName: " + fileName);
FileManager fileManager = fileManagerFactory.create(path); FileManager fileManager = fileManagerFactory.create(path);
if(fileManager.getList().contains(path.resolve(DEFAULT_SAVE_DIR))) { if(fileManager.getList().contains(path.resolve(DEFAULT_SAVE_DIR))) {
logger.debug("addNewPageToLast", "raw dir found");
fileManager.changeDir(DEFAULT_SAVE_DIR); fileManager.changeDir(DEFAULT_SAVE_DIR);
} else { } else {
logger.debug("addNewPageToLast", "raw dir not found");
fileManager.createDir(DEFAULT_SAVE_DIR); fileManager.createDir(DEFAULT_SAVE_DIR);
fileManager.changeDir(DEFAULT_SAVE_DIR); fileManager.changeDir(DEFAULT_SAVE_DIR);
} }