首页
外语
计算机
考研
公务员
职业资格
财经
工程
司法
医学
专升本
自考
实用职业技能
登录
计算机
In looking at the class structure of an entire system, we may find that its inheritance (1) is either wide and shallow, narrow a
In looking at the class structure of an entire system, we may find that its inheritance (1) is either wide and shallow, narrow a
admin
2009-09-04
50
问题
In looking at the class structure of an entire system, we may find that its inheritance (1) is either wide and shallow, narrow and deep, or balanced. Class structures that are wide and shallow usually represent forests of (2) classes that can be mixed and matched. Class structures that are narrow and deep represent trees of classes that are related by a common ancestor. There are advantages and disadvantages to each approach. Forests of classes are more loosely (3) , but they may not exploit all the commonality that exists. Trees of classes exploit this commonality, so that individual classes are smaller than in forests. However, to understand a particular class, it is usually necessary to understand the meaning of all the classes it inherits from or uses. The proper shape of a class structure is highly problem-dependent. We must make similar trade-offs among inheritance, aggregation, and using relation- ships. For example, should the class Car inherit, contain, or use the classes named Engine and Wheel? In this case, we suggest that an (4) relationship is more appropriate than inheritance relationship. Meyer states that between the class A and B," (5) is appropriate if every instance of B may also be viewed as an instance of A. The client relationship is appropriate when every instance of B simply possesses one or more attributes of A". From another perspective, if the behavior of an object is more than the sum of its individual parts, then creating an aggregation relationship rather than an inheritance relationship between the appropriate classes is probably superior.
选项
A、distinction
B、level
C、grade
D、hierarchy
答案
D
解析
转载请注明原文地址:https://kaotiyun.com/show/4rxZ777K
本试题收录于:
软件设计师上午基础知识考试题库软考中级分类
0
软件设计师上午基础知识考试
软考中级
相关试题推荐
基于TCP/IP的互联网服务中,IP协议提供主机之间的(42)分组传输服务。TCP协议提供端口之间的(43)文传输服务;U-DP属于(44)协议,从其下一层接收了数据以后,根据(45)将之分解咸UDP数据报;应用层的(46)协议可以使用UDP或TCP协议传
在Linux系统的路由配置中,若设置静态路由,则需(17)命令。在使用该命令时为了防止出现错误,可以将网络名字代替网络号,而网络名字可以在文件(18)中定义。为了将手工配置的命令存储下来,在系统启动时自动执行,可以通过(19)来实现。若运行动态路由,则(2
网络的拓扑设计对通信子网有许多重大的影响,下列(13)与网络的拓扑设计无关。
一般认为决定局域网特性的主要技术有三个,它们是(20)。
下面有关NTPS文件系统优点的描述中,(18)是不正确的。要把FAT32分区转换为NTFS分区,并且保留原分区中的所有文件,不可行的方法是(19)。
阅读以下说明,回答下面问题。【说明】短消息是指简短的字符信息,在短消息通信系统里,则指由短消息实体发起,通过移动网络传输到指定目的地址的有限长度的文本信息,近几年,短消息服务得到广泛应用。基于web的短消息服务平台的系统结构如图3.4所示。w
FrameRelayissimplifiedformof(71),similarinprincipleto(72),inwhichsynchronous,framesofdataareroutedtodifferent
OSPF协议适用于4种网络。下面的选项中,属于广播多址网络(BroadcastMulti-Ac-cess)的是(),属于非广播多址网络(NoneBroadcastMulti-Access)的是()。
某LinuxDHCP服务器dhcpd.conf的配置文件如下:ddns-update-stylenone;subnet192.168.0.0netmask255.255.255.0{range192.168.0.200
随机试题
当事人双方约定出租人按照承租人的要求出资向第三人购买租赁物,交付承租人使用、收益,承租人支付约定租金,并于合同期满后返还或购买租赁物的合同是()
下列哪项不符合世界卫生组织提出癌症三阶梯止痛治疗方案的原则
城市一次送电电压为()。
下列哪些财产可以抵押()。
关于矿业工程施工测量控制网布设原则的说法,错误的是()。
根据《建设工程工程量清单计价规范》(GB50500——2013),采用工程量清单招标的工程,投标人在投标报价时不得作为竞争性费用的是()。
在海洋争议问题上,过去我们一直提倡“搁置争议,共同开发”,但是从________上讲,如果不强调主权在我,“搁置争议”在某种程度上容易被________为主权存在争议;“共同开发”,本意是双方商量好再来开发,可是某种程度上,你开发你的,我开发我的,容易被_
垄断资本在国内建立垄断统治,必然要把其统治势力扩展到国外,建立国际垄断统治。垄断资本向世界范围扩展的基本形式有()
在计算机的硬件技术中,构成存储器的最小单位是
【C1】______hundredsofyears,artistshavebeencraftingbeautifulteapotstobrewjusttheright【C2】______oftea.TheYixing
最新回复
(
0
)