Skip to main content

http_type/status/
enum.rs

1use crate::*;
2
3/// Represents the execution status of a server hook.
4///
5/// This enum is used to control the request processing pipeline flow.
6/// When a hook returns `Reject`, the pipeline stops processing further hooks
7/// and the connection lifecycle is aborted. When a hook returns `Continue`,
8/// the pipeline proceeds to the next hook or stage.
9#[derive(Clone, Copy, Debug, Default, Deserialize, Eq, PartialEq, Serialize)]
10pub enum Status {
11    /// Indicates that the request processing should continue to the next hook or stage.
12    Continue,
13    /// Indicates that the request processing should be aborted and no further hooks should be executed.
14    #[default]
15    Reject,
16}