pub enum Error {
ImportFailed {
message: String,
},
FileError {
message: String,
},
InvalidParameter {
message: String,
},
OutOfMemory,
UnsupportedFormat {
format: String,
},
IoError {
message: String,
},
LoggingError {
message: String,
},
InvalidScene {
message: String,
},
StringConversion(Utf8Error),
NullPointer,
Other {
message: String,
},
}
Expand description
Errors that can occur during asset import/export operations
Variants§
ImportFailed
Import operation failed
FileError
Invalid file path or file not found
InvalidParameter
Invalid parameters or configuration
OutOfMemory
Memory allocation failed
UnsupportedFormat
Unsupported file format
IoError
I/O operation failed
LoggingError
Logging operation failed
InvalidScene
Invalid scene data
StringConversion(Utf8Error)
String conversion error (UTF-8)
NullPointer
Null pointer error
Other
Generic error with custom message
Implementations§
Source§impl Error
impl Error
Sourcepub fn import_failed<S: Into<String>>(message: S) -> Self
pub fn import_failed<S: Into<String>>(message: S) -> Self
Create a new import error
Sourcepub fn file_error<S: Into<String>>(message: S) -> Self
pub fn file_error<S: Into<String>>(message: S) -> Self
Create a new file error
Sourcepub fn invalid_parameter<S: Into<String>>(message: S) -> Self
pub fn invalid_parameter<S: Into<String>>(message: S) -> Self
Create a new invalid parameter error
Sourcepub fn unsupported_format<S: Into<String>>(format: S) -> Self
pub fn unsupported_format<S: Into<String>>(format: S) -> Self
Create a new unsupported format error
Sourcepub fn logging_error<S: Into<String>>(message: S) -> Self
pub fn logging_error<S: Into<String>>(message: S) -> Self
Create a new logging error
Sourcepub fn invalid_scene<S: Into<String>>(message: S) -> Self
pub fn invalid_scene<S: Into<String>>(message: S) -> Self
Create a new invalid scene error
Sourcepub fn from_assimp() -> Self
pub fn from_assimp() -> Self
Get the last error from Assimp
Trait Implementations§
Source§impl Error for Error
impl Error for Error
Source§fn source(&self) -> Option<&(dyn Error + 'static)>
fn source(&self) -> Option<&(dyn Error + 'static)>
Returns the lower-level source of this error, if any. Read more
1.0.0 · Source§fn description(&self) -> &str
fn description(&self) -> &str
👎Deprecated since 1.42.0: use the Display impl or to_string()
Auto Trait Implementations§
impl Freeze for Error
impl RefUnwindSafe for Error
impl Send for Error
impl Sync for Error
impl Unpin for Error
impl UnwindSafe for Error
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more