Class: RubyXL::DefinedNames

Inherits:
OOXMLContainerObject show all
Defined in:
lib/rubyXL/objects/workbook.rb

Overview

Instance Attribute Summary

Attributes included from OOXMLObjectInstanceMethods

#local_namespaces

Instance Method Summary collapse

Methods inherited from OOXMLContainerObject

#before_write_xml, define_count_attribute, #initialize, #inspect

Methods included from OOXMLObjectInstanceMethods

#==, #before_write_xml, included, #index_in_collection, #initialize, #write_xml

Constructor Details

This class inherits a constructor from RubyXL::OOXMLContainerObject

Instance Method Details

#[](key) ⇒ Object



150
151
152
153
154
155
# File 'lib/rubyXL/objects/workbook.rb', line 150

def [](key)
  case key
  when Integer then super
  when String then defined_names.find { |n| n.name = key }
  end
end