diff options
| author | nsfisis <nsfisis@gmail.com> | 2026-05-12 02:39:50 +0900 |
|---|---|---|
| committer | nsfisis <nsfisis@gmail.com> | 2026-05-12 02:39:50 +0900 |
| commit | 598ecbb3900dc08d571a1bdccab0b9cafdc34c08 (patch) | |
| tree | 2a198fab7e07a4c7a1a62b5df7d076a86ae1e59c /crates/shirabe/src/downloader/filesystem_exception.rs | |
| parent | 825330d83d86048816b6e09bdc444b224a8809a0 (diff) | |
| download | php-shirabe-598ecbb3900dc08d571a1bdccab0b9cafdc34c08.tar.gz php-shirabe-598ecbb3900dc08d571a1bdccab0b9cafdc34c08.tar.zst php-shirabe-598ecbb3900dc08d571a1bdccab0b9cafdc34c08.zip | |
feat(port): port FilesystemException.php
Diffstat (limited to 'crates/shirabe/src/downloader/filesystem_exception.rs')
| -rw-r--r-- | crates/shirabe/src/downloader/filesystem_exception.rs | 14 |
1 files changed, 14 insertions, 0 deletions
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, + }) + } +} |
