class AFCSalesforce::Tools::Validation::Rule::NotNil
Rule
for not nil
Public Instance Methods
error(value)
click to toggle source
# File lib/afc_salesforce/tools/validation/rule/not_nil.rb, line 12 def error(value) results = {} results[:expected] = true results[:got] = valid_value?(value) results end
error_key()
click to toggle source
The error key for this field
# File lib/afc_salesforce/tools/validation/rule/not_nil.rb, line 25 def error_key :not_nil end
params()
click to toggle source
This rule has no params
# File lib/afc_salesforce/tools/validation/rule/not_nil.rb, line 8 def params {} end
valid_value?(value)
click to toggle source
Determines if value is nil or not.
# File lib/afc_salesforce/tools/validation/rule/not_nil.rb, line 20 def valid_value?(value) !value.nil? end