ã¢ã¯ã»ãµãå«ããªãã¸ã§ã¯ãã§ãããã¿ã¤ããæ¡å¼µãã JavaScript MochiKitã®updateããPrototype.jsã®extendãªã©ã¯ããããã¿ã¤ãã«å¯¾ãã¦ã¢ã¯ã»ãµãå«ããªãã¸ã§ã¯ãã§ä¸æ¸ãã§ããªãã (ãããã¥ããã£ããã) update(Person.prototype, { get name(){ ... }, set name(name){ ... }, }) ãã®å ´åã¯ãå¥é__defineGetter__ã¨__defineSetter__ã§ãåå¥ã«ã¢ã¯ã»ãµãå®ç¾©ããªãã¦ã¯ãããªãã Person.prototype.__defineGetter__('name', function(){...}); Person.prototype.__defineSetter__('name', function(name){...}); åé·ã«ãªãããã以ä¸ã®ãããªé¢æ°ã§
{{#tags}}- {{label}}
{{/tags}}