{"blog_url":"https://unageanu.hatenablog.com/","author_name":"unageanu","author_url":"https://blog.hatena.ne.jp/unageanu/","width":"100%","published":"2007-12-24 20:56:25","url":"https://unageanu.hatenablog.com/entry/20071224/1198497385","title":" delegate\u3067\u30d7\u30ed\u30c8\u30bf\u30a4\u30d7\u30d9\u30fc\u30b9\u7d99\u627f","description":"delegate\u3092\u4f7f\u3046\u3068\u3001\u4efb\u610f\u306e\u30aa\u30d6\u30b8\u30a7\u30af\u30c8\u306b\u51e6\u7406\u3092\u79fb\u8b72\u3059\u308b\u30af\u30e9\u30b9\u3092\u4f5c\u308b\u3053\u3068\u304c\u3067\u304d\u307e\u3059\u3002\u3053\u308c\u3092\u5229\u7528\u3057\u3066JavaScript\u306a\u30d7\u30ed\u30c8\u30bf\u30a4\u30d7\u30d9\u30fc\u30b9\u3063\u307d\u3044\u7d99\u627f\u304c\u3067\u304d\u307e\u3059\u3002 require 'delegate' #super\u30af\u30e9\u30b9 class Animal def walk () puts \"teku teku.\" end end #sub\u30af\u30e9\u30b9 #SimpleDelegator\u3092\u7d99\u627f\u3057\u30d7\u30ed\u30c8\u30bf\u30a4\u30d7\u306b\u51e6\u7406\u3092\u79fb\u8b72\u3059\u308b\u3002 class Kitten < SimpleDelegator def initialize() super(PROTOTYPE) end # Kitten\u306e\u30d7\u30ed\u30c8\u30bf\u30a4\u30d7 PROTOTYP\u2026","blog_title":"\u3046\u306a\u306e\u65e5\u8a18","image_url":null,"provider_url":"https://hatena.blog","categories":["Ruby"],"height":"190","html":"<iframe src=\"https://hatenablog-parts.com/embed?url=https%3A%2F%2Funageanu.hatenablog.com%2Fentry%2F20071224%2F1198497385\" title=\" delegate\u3067\u30d7\u30ed\u30c8\u30bf\u30a4\u30d7\u30d9\u30fc\u30b9\u7d99\u627f - \u3046\u306a\u306e\u65e5\u8a18\" class=\"embed-card embed-blogcard\" scrolling=\"no\" frameborder=\"0\" style=\"display: block; width: 100%; height: 190px; max-width: 500px; margin: 10px 0px;\"></iframe>","version":"1.0","type":"rich","provider_name":"Hatena Blog"}