虚方法 [英] virtual method

查看:144
本文介绍了虚方法的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

你好,我的朋友们
我有一个问题,谁可以帮助我?
我的问题:虚方法与动态绑定之间的关系是什么? Thanx:rose:

Hello my friends
I have a question,who can to help me??
My question: What is relationship between virtual method an dynamic binding???
Thanx:rose:

推荐答案

问题是,要了解A和B之间的关系,您应该首先了解有关A和B的知识.

从查询来看,您似乎并不了解虚拟方法或动态绑定.如果您知道,就不会问这个.

那么,为什么不读这些书呢?一本关于C ++或OOP的好书通常应该会有所帮助.
The problem is that to know the relationship between A and B, you should first know something about A and B.

And from the query, it doesn''t look like you know about virtual methods or dynamic binding. Had you known, you wouldn''t have asked this.

So, why not read up on those? A good book on C++ or OOP in general should help.


多态性是OOP的支柱之一.如果您对此基本原理有疑问,那么该是买一本关于OOP的好书的时候了.
维基百科的一些介绍性信息.
Polymorphism is one of the pillars of OOP. If you have such doubts on this fundamentals then is time to buy a good book on OOP.
Some introductory info at Wikipedia.


我能理解:-O,
虚拟技术确实提供了动态绑定 [
I could understand :-O ,
that the virtual technique does provide the dynamic binding[^] :)


这篇关于虚方法的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆