Added Start, Stop, Kill, Send command

This commit is contained in:
2025-12-03 21:21:38 +01:00
parent 339be7f5c6
commit 377ca8b00b
5 changed files with 270 additions and 20 deletions

View File

@@ -63,4 +63,28 @@ pub enum SubscribeError {
NoStdout,
}
#[derive(Debug, Clone, Error)]
pub enum ServerError {
#[error("Server is already running")]
AlreadyRunning,
#[error("Server is not running")]
NotRunning,
#[error("Server crashed early")]
EarlyCrash,
#[error("Failed to run java command")]
CommandFailed,
#[error("Failed to access child stdout pipe")]
NoStdoutPipe,
#[error("Failed to access child stdin pipe")]
NoStdinPipe,
#[error("Failed to write to stdin")]
StdinWriteFailed,
}
type Result<T> = std::result::Result<T, Error>;