摘要: 类式继承//extend functionfunction extend(subClass,superClass){ var F=function(){}; F.prototype=superClass.prototype; subClass.prototype=new F(); subCl... 阅读全文
posted @ 2015-05-19 17:38 Byronvis 阅读(163) 评论(0) 推荐(0) 编辑
摘要: // Interface Constructorvar Interface=function(name,methods){ if(arguments.length!=2){ throw new Error("Interface constructor called with "+argume... 阅读全文
posted @ 2015-05-19 12:47 Byronvis 阅读(136) 评论(0) 推荐(0) 编辑