Module: Ocs::Document::Patches::Ocs::Resources::Base::ClassMethods

Defined in:
lib/ocs/document/generator.rb,
lib/ocs/document/patches/ocs/resources/base.rb

Instance Method Summary collapse

Instance Method Details

#define_attribute(attribute_name, type:) ⇒ Object



8
9
10
11
# File 'lib/ocs/document/patches/ocs/resources/base.rb', line 8

def define_attribute(attribute_name, type:)
  ::Ocs::Document::Generator.resources[to_s.split(/::/).last][attribute_name] = {type: type}
  super
end