pub fn int(params: &[Value]) -> NativeResultExpand description
Converts a Value::Boolean or a Value::String to an integer Value::Number.
- Declaration:
int(value: Any): Number
ยงErrors
Will return NativeError::CustomError if the Value can not be converted to a Number.
Will return NativeError::WrongParameterCount if there is a mismatch in the supplied parameters.
Will return NativeError::WrongParameterType if the the supplied parameters have the wrong type.