khive_pack_template/
lib.rs1pub mod handlers;
4mod pack;
5pub mod vocab;
6
7use khive_runtime::KhiveRuntime;
8use khive_types::{HandlerDef, Pack};
9
10pub(crate) use pack::TEMPLATE_HANDLERS;
11
12pub(crate) const PACK_NAME: &str = "template";
14
15pub struct TemplatePack {
19 runtime: KhiveRuntime,
20}
21
22impl Pack for TemplatePack {
23 const NAME: &'static str = PACK_NAME;
24 const NOTE_KINDS: &'static [&'static str] = vocab::NOTE_KINDS;
26 const ENTITY_KINDS: &'static [&'static str] = vocab::ENTITY_KINDS;
28 const HANDLERS: &'static [HandlerDef] = &TEMPLATE_HANDLERS;
30 const REQUIRES: &'static [&'static str] = &["kg"];
32}
33
34impl TemplatePack {
35 pub fn new(runtime: KhiveRuntime) -> Self {
37 Self { runtime }
38 }
39 pub(crate) fn runtime(&self) -> &KhiveRuntime {
40 &self.runtime
41 }
42}