From 598ecbb3900dc08d571a1bdccab0b9cafdc34c08 Mon Sep 17 00:00:00 2001 From: nsfisis Date: Tue, 12 May 2026 02:39:50 +0900 Subject: feat(port): port FilesystemException.php --- crates/shirabe/src/downloader/filesystem_exception.rs | 14 ++++++++++++++ 1 file changed, 14 insertions(+) (limited to 'crates/shirabe') diff --git a/crates/shirabe/src/downloader/filesystem_exception.rs b/crates/shirabe/src/downloader/filesystem_exception.rs index ddea31f..f861306 100644 --- a/crates/shirabe/src/downloader/filesystem_exception.rs +++ b/crates/shirabe/src/downloader/filesystem_exception.rs @@ -1 +1,15 @@ //! ref: composer/src/Composer/Downloader/FilesystemException.php + +use shirabe_php_shim::Exception; + +#[derive(Debug)] +pub struct FilesystemException(pub Exception); + +impl FilesystemException { + pub fn new(message: String, code: i64) -> Self { + FilesystemException(Exception { + message: format!("Filesystem exception: \n{}", message), + code, + }) + } +} -- cgit v1.3.1