{"author_name":"obelisk2","published":"2017-09-14 21:05:17","url":"https://marginalia.hatenablog.com/entry/20170914/1505390717","version":"1.0","type":"rich","categories":["Ruby"],"description":"~/Documents/Ruby/\u30b3\u30fc\u30c9\u30ea\u30fc\u30c7\u30a3\u30f3\u30b0/ostruct.rb \u306e\u4e00\u90e8 class OpenStruct def initialize(hash=nil) #Hash{@table} @table = {} if hash hash.each_pair do |k, v| k = k.to_sym @table[k] = v end end end attr_reader :table def modifiable #@modifiable >> Hash{@table} begin @modifiable = true #@modefiable \u306f\u4ed6\u306b\u51fa\u3066\u3053\u306a\u3044\u3002 rescue \u2026","blog_title":"Marginalia","image_url":null,"provider_name":"Hatena Blog","html":"<iframe src=\"https://hatenablog-parts.com/embed?url=https%3A%2F%2Fmarginalia.hatenablog.com%2Fentry%2F20170914%2F1505390717\" title=\"OpenStruct \u306e\u30b3\u30fc\u30c9\u30ea\u30fc\u30c7\u30a3\u30f3\u30b0\uff08Ruby\uff09 - Marginalia\" class=\"embed-card embed-blogcard\" scrolling=\"no\" frameborder=\"0\" style=\"display: block; width: 100%; height: 190px; max-width: 500px; margin: 10px 0px;\"></iframe>","width":"100%","author_url":"https://blog.hatena.ne.jp/obelisk2/","provider_url":"https://hatena.blog","blog_url":"https://marginalia.hatenablog.com/","height":"190","title":"OpenStruct \u306e\u30b3\u30fc\u30c9\u30ea\u30fc\u30c7\u30a3\u30f3\u30b0\uff08Ruby\uff09"}