随笔分类 -  面向对象

摘要:炉石传说 弩炮射击(Ballista Shot)Ballista Shot弩炮射击Hero Power Deal 3 damage.英雄技能 造成3点伤害。 稳固射击(Steady Shot)Steady Shot稳固射击Hero Power Deal 2 damage.英雄技能 造成2点伤害。 实 阅读全文
posted @ 2019-09-08 17:09 ChuckLu 阅读(341) 评论(0) 推荐(0) 编辑
摘要:https://stackoverflow.com/questions/49002/prefer-composition-over-inheritance 解答1 Prefer composition over inheritance as it is more malleable / easy t 阅读全文
posted @ 2019-02-01 10:52 ChuckLu 阅读(518) 评论(0) 推荐(0) 编辑
摘要:What is the difference between DAO and DAL?The Data Access Layer (DAL) is the layer of a system that exists between the business logic layer and the p... 阅读全文
posted @ 2016-01-04 15:01 ChuckLu 阅读(455) 评论(0) 推荐(0) 编辑
摘要:http://pcedu.pconline.com.cn/empolder/gj/c/0504/609482_1.html 阅读全文
posted @ 2015-05-13 09:50 ChuckLu 阅读(189) 评论(0) 推荐(0) 编辑
摘要:http://bbs.csdn.net/topics/220013605【18楼】打个比方,让你编一个计算正方形的程序,一般的思路是:定义3个变量,a=长,b=宽,c=a*b而面向对象的思路:先创建一个长方形的类,在类里定义两个属性分别为长、宽,再定义一个面积方法然后实例化这个类【19楼】你这样的例... 阅读全文
posted @ 2015-05-13 09:48 ChuckLu 阅读(209) 评论(0) 推荐(0) 编辑
摘要:输出结果是 A a = new A(); B b = new B(); a.Fun2(b); 将子类B的实例b作为参数传递给父类A的引用a1。Fun2的this是父类的实例a a1.Fun1(1); 输出2 因为父类的变量a1里实际存储的是子类的实例b,所以这里调用的是子类Fun1 Fun1(5); 阅读全文
posted @ 2015-04-28 16:30 ChuckLu 阅读(300) 评论(0) 推荐(0) 编辑

点击右上角即可分享
微信分享提示