Class: Ufebs::Entities::EdDefineRequestInfo

Inherits:
Object
  • Object
show all
Includes:
HappyMapper
Defined in:
lib/ufebs/entities/ed_define_request_info.rb

Instance Method Summary collapse

Constructor Details

#initialize(params = {}) ⇒ EdDefineRequestInfo

Returns a new instance of EdDefineRequestInfo.



30
31
32
33
34
35
36
37
38
# File 'lib/ufebs/entities/ed_define_request_info.rb', line 30

def initialize(params = {})
  params.each do |key, value|
    case key.to_sym
    when :ed_field_lists         then set_ed_field_lists(value)
    when :ed_define_reestr_infos then set_ed_define_reestr_infos(value)
    else instance_variable_set("@#{key}".to_sym, value)
    end
  end
end

Instance Method Details

#set_ed_define_reestr_infos(value) ⇒ Object



45
46
47
48
# File 'lib/ufebs/entities/ed_define_request_info.rb', line 45

def set_ed_define_reestr_infos(value)
  @ed_define_reestr_infos =
    value.map { |params| Ufebs::Entities::EdReestrInfo.new(params) }
end

#set_ed_field_lists(value) ⇒ Object



40
41
42
43
# File 'lib/ufebs/entities/ed_define_request_info.rb', line 40

def set_ed_field_lists(value)
  @ed_field_lists =
    value.map { |params| Ufebs::Entities::EdFieldList.new(params) }
end