(&self, args: &[Value], _context: &Context)
| 26 | } |
| 27 | |
| 28 | fn invoke(&self, args: &[Value], _context: &Context) -> Result<Value, DscError> { |
| 29 | debug!("{}", t!("functions.not.invoked")); |
| 30 | if let Some(arg1) = args[0].as_bool() { |
| 31 | Ok(Value::Bool(!arg1)) |
| 32 | } else { |
| 33 | Err(DscError::Parser(t!("functions.invalidArguments").to_string())) |
| 34 | } |
| 35 | } |
| 36 | } |
| 37 | |
| 38 | #[cfg(test)] |