Returns the canonical string representation of this hook type.
(&self)
| 225 | |
| 226 | /// Returns the canonical string representation of this hook type. |
| 227 | pub fn as_str(&self) -> &'static str { |
| 228 | match self { |
| 229 | HookType::SessionStart => "session_start", |
| 230 | HookType::SessionEnd => "session_end", |
| 231 | HookType::TurnStart => "turn_start", |
| 232 | HookType::TurnEnd => "turn_end", |
| 233 | HookType::PreToolUse => "pre_tool_use", |
| 234 | HookType::PostToolUse => "post_tool_use", |
| 235 | } |
| 236 | } |
| 237 | } |
| 238 | |
| 239 | impl fmt::Display for HookType { |
no outgoing calls