Class: ValidatorsHelper::ValidationTester

Inherits:
Object
  • Object
show all
Extended by:
ActiveModel::Naming
Includes:
ActiveModel::Conversion, ActiveModel::Validations
Defined in:
app/helpers/validators_helper.rb

Class Method Summary collapse

Instance Method Summary collapse

Class Method Details

.nameObject



17
18
19
# File 'app/helpers/validators_helper.rb', line 17

def self.name
  'Validator'
end

Instance Method Details

#[](key) ⇒ Object



21
22
23
# File 'app/helpers/validators_helper.rb', line 21

def [](key)
  send(key)
end

#[]=(key, value) ⇒ Object



25
26
27
# File 'app/helpers/validators_helper.rb', line 25

def []=(key, value)
  send("#{key}=", value)
end

#new_record?Boolean

Returns:

  • (Boolean)


9
10
11
# File 'app/helpers/validators_helper.rb', line 9

def new_record?
  true
end

#persisted?Boolean

Returns:

  • (Boolean)


13
14
15
# File 'app/helpers/validators_helper.rb', line 13

def persisted?
  false
end