Class: ValidationConfig
- Inherits:
-
Object
- Object
- ValidationConfig
- Defined in:
- lib/casey_jones/validation/j_query_validator.rb
Instance Attribute Summary collapse
-
#config ⇒ Object
Returns the value of attribute config.
Instance Method Summary collapse
- #email ⇒ Object
-
#initialize ⇒ ValidationConfig
constructor
A new instance of ValidationConfig.
- #min_length(i) ⇒ Object
- #url ⇒ Object
Constructor Details
#initialize ⇒ ValidationConfig
Returns a new instance of ValidationConfig.
20 |
# File 'lib/casey_jones/validation/j_query_validator.rb', line 20 def initialize; self.config = {}; end |
Instance Attribute Details
#config ⇒ Object
Returns the value of attribute config.
19 20 21 |
# File 'lib/casey_jones/validation/j_query_validator.rb', line 19 def config @config end |
Instance Method Details
#email ⇒ Object
22 23 24 25 |
# File 'lib/casey_jones/validation/j_query_validator.rb', line 22 def email self.config[:email] = true return self end |
#min_length(i) ⇒ Object
27 28 29 30 |
# File 'lib/casey_jones/validation/j_query_validator.rb', line 27 def min_length(i) self.config[:minlength] = i return self end |
#url ⇒ Object
32 33 34 35 |
# File 'lib/casey_jones/validation/j_query_validator.rb', line 32 def url self.config[:url] = true return self end |