mirror of
https://github.com/lacerta-doc/Lacerta.git
synced 2024-11-26 17:53:14 +00:00
リファクタリング
This commit is contained in:
parent
78525d634a
commit
f36dc05db1
|
@ -187,8 +187,7 @@ public class FileManagerImpl implements FileManager {
|
||||||
}
|
}
|
||||||
private void saveBitmapInternal(Bitmap bitmap) throws IOException {
|
private void saveBitmapInternal(Bitmap bitmap) throws IOException {
|
||||||
try {
|
try {
|
||||||
File file = this.path.toFile();
|
bitmap.compress(Bitmap.CompressFormat.PNG, 100, Files.newOutputStream(this.path));
|
||||||
bitmap.compress(Bitmap.CompressFormat.PNG, 100, Files.newOutputStream(file.toPath()));
|
|
||||||
} catch (Exception e) {
|
} catch (Exception e) {
|
||||||
logger.error("saveBitmapInternal", e.getMessage());
|
logger.error("saveBitmapInternal", e.getMessage());
|
||||||
throw new IOException("Failed to save bitmap");
|
throw new IOException("Failed to save bitmap");
|
||||||
|
|
Loading…
Reference in New Issue
Block a user