MCPcopy Create free account
hub / github.com/cel-rust/cel-rust / add

Method add

cel/src/magic.rs:286–293  ·  view source on GitHub ↗
(&mut self, name: &str, function: F)

Source from the content-addressed store, hash-verified

284
285impl FunctionRegistry {
286 pub(crate) fn add<F, T>(&mut self, name: &str, function: F)
287 where
288 F: IntoFunction<T> + 'static + Send + Sync,
289 T: 'static,
290 {
291 self.functions
292 .insert(name.to_string(), function.into_function());
293 }
294
295 #[allow(dead_code)]
296 pub(crate) fn get(&self, name: &str) -> Option<&Function> {

Callers 1

add_functionMethod · 0.45

Calls 1

into_functionMethod · 0.80

Tested by

no test coverage detected