OOP技术由对象、消息、方法、类和继承五个方面组成。
OOP consists of five aspects: object, message, method, class and inheritance.
总之,该部分讨论了UML和类图、继承、多态性、封装…一些应该在开头为您介绍的东西。
Anyway, this section talks about UML and class diagrams, inheritance, polymorphism, encapsulation... things they should have shown you in the beginning.
继承允许您在新的类中重用和自定义现有的代码。
Inheritance allows you to reuse and customize existing code inside a new class.
或许我们需要的是一种全新的继承术语,用于描述特征和实现类之间的关系。
Perhaps what we need is a new inheritance phrase, IN-TERMS-OF, to describe the relationship between a trait and an implementing class.
该套件的目标就是展示代码中显露出来的关系(方法调用、继承等等)和运行时出现的关系(对接口或基类的调用)。
The goal for the suite is to show any relationship that is either explicitly in the code (method calls, inheritance, etc) or done so at runtime (calls to interfaces or base classes).
本文假设读者熟悉基本的面向对象概念,比如类、对象、方法和继承。
This article assumes you are familiar with basic object-oriented concepts, such as classes, objects, methods, and inheritance.
继承:标注——单个表、联合表和按类表。
Inheritance: Annotations — Single table, joined table, and table per class.
从好的方面看,继承的 _metaclass_钩子和自定义元类的所有问题都被解决了
On the plus side, all issues for inherited _metaclass_ hooks and for custom metaclasses are handled
图2显示了DictionaryIO和xmldictionaryio类之间的继承关系。
Figure 2 shows the inheritance relationship between the DictionaryIO and XmlDictionaryIO classes.
在图10中显示的图中,Professor和Student类都实现了Person的接口,但并不从它继承。
In the diagram shown in Figure 10, both the Professor and Student classes implement the Person interface and do not inherit from it.
顶层对象是Order,是FoodOrder和BoxOrder继承的一个抽象类。
The top level object is the Order, an abstract class that is inherited by FoodOrder and BoxOrder.
你可以导航到使用,声明,继承,基类和更多—交叉语言。
You can navigate to usages, declarations, inheritors, base types and more - across languages.
同时提供接口和抽象类是多余的,但我发现这样很方便:在大多数情况下,我只需要抽象类,但接口支持多继承性。
Offering both an interface and an abstract class is redundant, but I find it convenient: in most cases, I only need the abstract class, but the interface enables multiple inheritance.
OOAD试图找到最优的对象和最自然的类继承来实现它们。
OOAD attempts to find the optimal set of objects and the most natural class hierarchy to implement them.
用户必须理解元类编程和传统面向对象编程的不同点和相同点(单继承和多继承)。
Users must understand the differences and interactions between metaclass programming and traditional object-oriented programming (under both single and multiple inheritance).
CarlosDriscoll博士认为继承和所有权的概念也许正是由于最早融入人类社会的犬类们所激发,使它们从群狼变成了财富的象征。
Notions of inheritance and ownership, Dr. Driscoll said, may have been prompted by the first dogs to permeate human society, laying an unexpected track from Wolf to wealth.
这些克隆类必须使用和域类本身一样的名字(但两者在不同的包中),并且继承LazyGwtPojo。
Theses clone classes must have the same name than the Domain class (in a different package) and inherits from LazyGwtPojo.
这个应用程序继承了midlet类,以允许应用程序管理软件对MIDlet进行控制、从应用程序描述符检索属性以及对状态变化进行通知和请求。
The application extends the MIDlet class to allow the application management software to control the MIDlet, retrieve properties from the application descriptor, and notify and request state changes.
继承DictionaryIO的任何类必须实现import和export方法,否则就可能得到致命错误。
Any class that extends DictionaryIO must implement the import and export methods or risk a fatal error.
它继承org .eclipse . ui .editors包中包括的类,这个包为eclipse平台提供一个标准文本编辑器和基于文件的文档提供程序。
It extends classes included in the org.eclipse.ui.editors package, which provides a standard text editor and a file-based document provider for the eclipse Platform.
所有派生实体类和会话类都继承了bobase类中create和find方法的公共代码。
All derived entity classes and the session class inherit the common code of the create and find methods from the BOBase class.
类的API目前包含对于继承和超类方法调用的完善支持。
The class API now includes full support for inheritance and superclass method calls. (See Mislav's tutorial for more info.)
而FoodOrder则是由这三种食品类型实际订单类(Doughnut、Pasty和IcedBun)继承的另一个抽象类。
Food order is another abstract class inherited by the three food types actual order classes: Doughnut, Pasty, and IcedBun.
接下来我们可以有一些具体的开关,例如一个漂亮开关,一个普通开关等等,当然,我们会让类FancySwitch和NormalS witchnd继承类s witch。
And, as we may have some specific kinds of switches, for example a fancy switch, a normal switch etc., we will also have FancySwitch and NormalSwitch classes extending the switch class.
下面一部分代码是实际的测试类(继承了上面的CustomerManagerContext类),实现了一些辅助方法和测试方法。
The next section of code is where the actual test class (derived from our CustomerManagerContext above) implements the auxiliary and test methods.
而且,因为两个映射的类(Building和Land)是从estate中继承而来,所以我们可以在HQL查询中使用这个抽象超类,如清单14所示。
And, since our two mapped classes (Building and Land) inherit from Estate, we can use this abstract superclass in our HQL queries, as shown in Listing 14.
在Flash7中引入了ActionScript 2.0,这是一种强类型的语言,支持基于类的编程特性,比如继承、接口和严格的数据类型。
ActionScript 2.0 was introduced in Flash 7, which was strongly typed and allowed class-based programming features, such as inheritance, interfaces, and strict data typing.
该类文件实际上包含一系列类,这些类继承并扩展了DataSet、DataTable、DataRow和eventargs类。
The class file actually contains a series of classes that inherit from and extend the DataSet, DataTable, DataRow, and EventArgs classes.
并且,和Array [t]相同,List [t]继承了很多基类和特性,首先使用Seq [t]作为直接上层基类。
And, like Array [t], List [t] inherits from a number of base classes and traits, starting with Seq [t] as an immediate base.
这个一个经典的转换例子在类继承和委托到一个接口。
This is a classic example of the tradeoff between concrete inheritance and delegation to an interface.
应用推荐