1
use crate::commands::{
2
    Command, Request, RequestParserResult, ResponseAttributes, ResponseParserError,
3
};
4

            
5
pub struct Kill;
6

            
7
impl Command for Kill {
8
    type Response = ();
9
    const COMMAND: &'static str = "kill";
10

            
11
    fn parse_request(mut parts: std::str::SplitWhitespace<'_>) -> RequestParserResult<'_> {
12
        debug_assert!(parts.next().is_none());
13
        Ok((Request::Kill, ""))
14
    }
15

            
16
    fn parse_response(
17
        parts: ResponseAttributes<'_>,
18
    ) -> Result<Self::Response, ResponseParserError> {
19
        debug_assert!(parts.is_empty());
20
        Ok(())
21
    }
22
}