7.5. Testing for numerical values: ocf_is_decimal

Specifically for parameter validation, it can be helpful to test whether a given value is numeric. The ocf_is_decimal function exists for that purpose:

foobar_validate_all() {
    if ! ocf_is_decimal $OCF_RESKEY_eggs; then
        ocf_log err "eggs is not numeric!"
        exit $OCF_ERR_CONFIGURED
    fi
    ...
}