Class: LMC::DeviceDSCUi::Section

Inherits:
Object
  • Object
show all
Defined in:
lib/lmc/config/device_dsc_ui.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(section_wrapper) ⇒ Section

Returns a new instance of Section.



50
51
52
53
54
55
56
57
58
# File 'lib/lmc/config/device_dsc_ui.rb', line 50

def initialize(section_wrapper)
  section = section_wrapper['section']
  @names = section['name']
  members = section['members']
  @groups = members.map { |group_wrapper|
    Group.new group_wrapper unless group_wrapper['group'].nil?
  }.compact

end

Instance Attribute Details

#groupsObject (readonly)

Returns the value of attribute groups.



48
49
50
# File 'lib/lmc/config/device_dsc_ui.rb', line 48

def groups
  @groups
end

#namesObject (readonly)

Returns the value of attribute names.



48
49
50
# File 'lib/lmc/config/device_dsc_ui.rb', line 48

def names
  @names
end