Module: Serega::Validations::CheckAttributeParams::InstanceMethods

Included in:
Serega::Validations::CheckAttributeParams
Defined in:
lib/serega/validations/check_attribute_params.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Instance Attribute Details

#blockObject (readonly)

Returns the value of attribute block.



7
8
9
# File 'lib/serega/validations/check_attribute_params.rb', line 7

def block
  @block
end

#nameObject (readonly)

Returns the value of attribute name.



7
8
9
# File 'lib/serega/validations/check_attribute_params.rb', line 7

def name
  @name
end

#optsObject (readonly)

Returns the value of attribute opts.



7
8
9
# File 'lib/serega/validations/check_attribute_params.rb', line 7

def opts
  @opts
end

Instance Method Details

#initialize(name, opts, block) ⇒ Object



9
10
11
12
13
# File 'lib/serega/validations/check_attribute_params.rb', line 9

def initialize(name, opts, block)
  @name = name
  @opts = opts
  @block = block
end

#validateObject



15
16
17
18
19
# File 'lib/serega/validations/check_attribute_params.rb', line 15

def validate
  check_name
  check_opts
  check_block
end