Class: Aequitas::VirtusIntegration::InlineAttributeRuleExtractor::Numeric

Inherits:
Object
  • Object
show all
Defined in:
lib/aequitas/virtus_integration/inline_attribute_rule_extractor/numeric.rb

Instance Attribute Summary

Attributes inherited from Object

#attribute

Instance Method Summary collapse

Methods inherited from Object

#extract_presence_rule, #extract_primitive_type_rule, #initialize, #options

Constructor Details

This class inherits a constructor from Aequitas::VirtusIntegration::InlineAttributeRuleExtractor::Object

Instance Method Details

#extractObject



10
11
12
13
# File 'lib/aequitas/virtus_integration/inline_attribute_rule_extractor/numeric.rb', line 10

def extract
  rules = super
  rules.concat Array(extract_value_rules)
end

#extract_value_rulesObject



15
16
17
# File 'lib/aequitas/virtus_integration/inline_attribute_rule_extractor/numeric.rb', line 15

def extract_value_rules
  Rule::Value.rules_for(attribute.name, options)
end