Class: RegexForms::ValidateCPF

Inherits:
Object
  • Object
show all
Defined in:
lib/regex_forms.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(cpf) ⇒ ValidateCPF

Returns a new instance of ValidateCPF.



11
12
13
# File 'lib/regex_forms.rb', line 11

def initialize(cpf)
  @cpf = cpf
end

Instance Attribute Details

#cpfObject (readonly)

Returns the value of attribute cpf.



9
10
11
# File 'lib/regex_forms.rb', line 9

def cpf
  @cpf
end

Instance Method Details

#validateObject



15
16
17
# File 'lib/regex_forms.rb', line 15

def validate
  regex_cpf(cpf)
end