Sha256: 13c2cdf4b9e39014d40993b05f5b6aaf359e29980146a608e730880e0d05d32a

Contents?: true

Size: 301 Bytes

Versions: 13

Compression:

Stored size: 301 Bytes

Contents

module Sample
  module HasProps

    def add_prop(key, value)
      @props = { } unless self.instance_variable_defined?(:@props)
      @props[key] = value
    end

    def props
      @props = { } unless self.instance_variable_defined?(:@props)
      @props
    end
    
  end # HasProps
end # Sample

Version data entries

13 entries across 13 versions & 1 rubygems

Version Path
oj-3.16.9 test/sample/hasprops.rb
oj-3.16.8 test/sample/hasprops.rb
oj-3.16.7 test/sample/hasprops.rb
oj-3.16.6 test/sample/hasprops.rb
oj-3.16.5 test/sample/hasprops.rb
oj-3.16.4 test/sample/hasprops.rb
oj-3.16.3 test/sample/hasprops.rb
oj-3.16.2 test/sample/hasprops.rb
oj-3.16.1 test/sample/hasprops.rb
oj-3.16.0 test/sample/hasprops.rb
oj-3.15.1 test/sample/hasprops.rb
oj-3.15.0 test/sample/hasprops.rb
oj-3.14.3 test/sample/hasprops.rb