pub enum FactorioExporterError {
FactorioExecutionError {
stdout: String,
stderr: String,
},
FactorioOutputError {
message: String,
output: String,
},
FileNotFoundError {
file: PathBuf,
},
InvocationError(String),
IoError(Error),
JsonParsingError(Error),
YamlParsingError(Error),
}
Expand description
Main error type used throughout factorio-explorer
Variants§
FactorioExecutionError
Error that is raised if Factorio could not be started to execute the exporter mods. The process output to stdout and stderr is saved in the error object.
FactorioOutputError
Error that is raised if Factorio’s output could not be parsed. This can have all kinds of root causes, but the underlying reason should normally be apparent from the process output stored in this error object.
FileNotFoundError
Error that is raised if a file couldn’t be found, for example the API spec or the Factorio binary. This is usually a user error.
InvocationError(String)
Error that is raised if the user specified conflicting or incomplete command line arguments.
IoError(Error)
Error that is raised if a file system operation failed unexpectedly.
JsonParsingError(Error)
Error that is raised if deserialization from JSON failed.
YamlParsingError(Error)
Error that is raised if deserialization from JSON failed.
Trait Implementations§
Source§impl Debug for FactorioExporterError
impl Debug for FactorioExporterError
Source§impl Display for FactorioExporterError
impl Display for FactorioExporterError
Source§impl Error for FactorioExporterError
impl Error for FactorioExporterError
Source§fn source(&self) -> Option<&(dyn Error + 'static)>
fn source(&self) -> Option<&(dyn Error + 'static)>
1.0.0 · Source§fn description(&self) -> &str
fn description(&self) -> &str
Source§impl From<Error> for FactorioExporterError
impl From<Error> for FactorioExporterError
Source§impl From<Error> for FactorioExporterError
impl From<Error> for FactorioExporterError
Auto Trait Implementations§
impl Freeze for FactorioExporterError
impl !RefUnwindSafe for FactorioExporterError
impl Send for FactorioExporterError
impl Sync for FactorioExporterError
impl Unpin for FactorioExporterError
impl !UnwindSafe for FactorioExporterError
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
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
self
into a Left
variant of Either<Self, Self>
if into_left
is true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
self
into a Left
variant of Either<Self, Self>
if into_left(&self)
returns true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read more