Visual C++ vs C++ Builder

WJM 2000-07-19 11:35:00
我想这篇贴子再这儿发表回引来很多不同意见,然而这正是我所想看到的。(这篇贴子我曾在商都BBS上贴过)

VC vs CB

1、从编译器角度看,CB强与VC。在编译小的程序时,CB的优势尤为明显。例如:用API写一段只显示一个窗口的win32程序时,CB编译的只有40多k,而VC却要80多k。但是,如果是用CB&VCL编程,情况就不同了,由于VCL时用OOPascal写的,编译时需链入额外的库,造成的结果是同样的程序,CB竟然比Delphi还大。是否比用VC&MFC写的程序大,我没有比较过,但我想这是肯定的。编译速度我没有定量比较过,感觉两者差不多,都比Delphi慢多了。

2、从编辑器角度看,VC强与CB。我想大家都会有同感。VC编辑器的智能化很好,当输入一个类名後,他会立刻以列表框方式显示所有定义的成员。CB(包括Delphi)也有同样功能,但反应速度太慢,等他反应过来,我已经输入8遍了。

3、MFC与OWL的优劣之分,是软件专家的事。本人才疏学浅,不敢妄议。但我认为把VCL放在一起和他们比较,是不妥的,因为他们根本是两码事。如果按标准叫法,前者是框架,后者叫构件。构件是以属性、方法、事件和程序员交互的,框架没有这些概念。构件确实给开发效率带来了好处,他也许是未来Visual Programming的发展趋势。Microsoft不是没有能力在VC中引入构件(VB的ocx不都是用VC写的吗),之所以Vc不采用他,我想大概是考虑到构件的使用会降低VC程序的执行效率。
OWL优于MFC,这种说法我不止一次见过。似乎已成定论。权且认为它是真理吧。然而OWL红颜薄命,由于市场的不成功,Borland也懒的给他升级。从Borland C++5 之后,这么多年了,未见OWL的新版问世。Borland却要向Microsoft购买MFC的许可权。但是,奸诈的Microsoft会把MFC的最新版的许可卖给Borland吗?不可能。
其实,OWL优于MFC之说,我也有点保留意见。MFC对API的封装很薄,薄到让你看见API的影子。这让熟悉API(SDK)编程的人看起来感到很亲切,乐于接受。而先学API编程,再学框架编程是成为Windows programmer的康庄大道。我没听说过哪个成功的Windows programmer不是这样走过来的。直接接受框架编程,会让你越学越糊涂。我有切身体会:本人曾借到一本书,好像是“24学时精通MFC",结果24天过去了,连第一章也没看懂。同时,MFC又比OWL好学(听说的,我不会OWL)。在这种情况下,读完了Petzold的Programming Windows,理所当然的该读MFC的书了,谁去学OWL呢?

4、从学习资源的角度看,CB远不如VC。CB的用户量比VC少的多,是你很难找到志同道合的朋友一起切磋;CB的参考书少(我指高水平的书,不是国人写的入门书),你不得不去买Delphi的书去学CB;CB的网上资源也少,(注:inprise的社区是最好的学CB的地方)。

5、最后一点、也是最重要的一点。记住:Windows是Microsoft的OS,VC是Microsoft为Windows设计的开发工具。最新的Windows技术,总是在MFC中得到实现。我认为,一个以Windows programming为职业的人(而不是作为业余爱好的人),应选VC为开发工具。个人认为如果不是对C++太热衷的话,选CB还不如选Delphi。也许CB会成为Linux下的最佳选择,但它还没有问世。

本人入道不久,见识尚浅,有写的不对之处,望各位网友指出。

注:对指出我的贴子中的错误的朋友,我将给分。


...全文
256 5 打赏 收藏 转发到动态 举报
写回复
用AI写文章
5 条回复
切换为时间正序
请发表友善的回复…
发表回复
xubin_sh 2000-08-09
  • 打赏
  • 举报
回复
cb编译出来有多大我不知道,但是vc6编译出来是 28,672byte 你可以试一下


tonyyang 2000-07-21
  • 打赏
  • 举报
回复
我认为Winsun 说的很有道理。从TC,BC++,VC++,Delphi,BCB没有永久的常胜将军,也没有完美无缺的工具。要根据Case的要求选工具。
xqiqi 2000-07-20
  • 打赏
  • 举报
回复
我觉得影响我们选择工具的因素里非技术因素很重要,比如我用VC就基于这样一些原因。VC软件是最容易得到的,VC的资料是最多的,VC是微软公司的产品,还有一点我个人认为很重要,就是微软不会倒,即使被分解。至于编译器效率、类库是否优秀,对我来说没有关系。
jiujiejushi 2000-07-19
  • 打赏
  • 举报
回复
我觉得影响我们选择工具的因素里非技术因素很重要,比如我用VC就基于这样一些原因。VC软件是最容易得到的,VC的资料是最多的,VC是微软公司的产品,还有一点我个人认为很重要,就是微软不会倒,即使被分解。至于编译器效率、类库是否优秀,对我来说没有关系。
Wingsun 2000-07-19
  • 打赏
  • 举报
回复
我认为在现在的条件下,程序的大小和速度不是一个程序的主要方面,重要的是功能。我们是一群靠编写程序为生的人,我们的目的是写程序,通过写程序来获得保证自己生存的所必需的物质条件。我们需要的是能够快速高效低编写的程序的东西,我们不是艺术家。BCB与VC的比较我只能从我的角度来考虑,根据我的需求和上司、客户的要求来选择使用什么样的工具。对于比较简单和要求迫切的工作我会使用BCB,对于要求较高,难度较大的我会考虑使用VC,但是他们绝对不是我的一个工程/项目中的唯一开发工具,我可能用到Delphi、VC、VB、BCB等等工具,对于我来说他们仅仅只是工具而已。工具嘛只要能实现你要的功能就行了,不必去看一看他究竟是姓什么的,Microsoft,Borland or sybase等。也没必要费那么大的劲去考察他们。
Borland C++Builder 5.0 (简介)   Borland C++Bilder 5.0是Interprise(Borland)公司推出的基于C++ 语言的快速应用程序开发(Rapid Application Development,RAD)工具,它是最先进的开发应用程序的组件思想和面向对象的高效语言C++融合的产物。C++Builder 充分利用了已经发展成熟的Delphi 的可视化组件库(Visual Component Library,VCL),吸收了Borland C++ 5.0 这个优秀编译器的诸多优点。C++Builder 结合了先进的基于组件的程序设计技术,成熟的可视化组件库和优秀编译器,调试器。发展到5.0版本,C++Builder 已经成为一个非常成熟的可视化应用程序开发工具,功能强大而且效率高。 C++Builder的特色: 1.C++Builder 是高性能的C++开发工具   C++Builder是基于C++的,它具有高速的编译,连接和执行速度。同时,C++Builder具有双编译器引擎,不仅可以编译C/C++程序,还能编译Object Pascal语言程序。 2.C++Builder是优秀的可视化应用程序开发工具   C++Builder是一完善的可视化应用程序开发工具,使程序员从繁重的代码编写中解放出来,使他们能将注意力重点放在程序的设计上,而不是简单的重复的劳动中。同时,它提供的完全可视的程序界面开发工具,从而使程序员对开发工具的学习周期大大缩短。 3.C++Builder具有强大的数据库应用程序开发功能   C++Builder 提供了强大的数据库处理功能,它使的程序员不用写一行代码就能开发出功能强大的数据库应用程序,这些主要依赖于C++Builder众多的数据库感知控件和底层的BDE数据库引擎。C++Builder除了支持MicroSoft的ADO(Active Data Object)数据库连接技术,还提供了一种自己开发的成熟的数据库连接技术——BDE(Borland Database Engine)数据库引擎。 4.C++Builder具有强大的网络编程能力 C++Builder具有众多的Internet应用程序开发控件,如WebBroker,CppWebBroswer,WinSocks等,它们基本含盖了Internet应用的全部功能,利用它们程序员可以方便地建立自己地Internet应用程序。
Introduction My desire to write a book about C++Builder has some history. I have beenvery impressed with Borland since their first edition of C++ (and prior editionsof C), because they have always made an effort to ensure quality. Unfortunately, there are very few books on the market about Borland C++or C++Builder, compared to other products like Visual Basic or VisualC++. Since different authors have different viewpoints of a product, I always prefer to consult more than one book to gain in-depth knowledge, as every author provides a unique service with his or her expertise. Also,authors are limited by their own onstraints; every book does not cover every aspect of the product. When I first used MIDAS a few years ago,there was not a book available to help me do my project. I spent a lot of time investigating answers for my questions in an iterative manner. I can say that my frustration over that prompted me to write this book on C++Builder. As with every release, C++Builder 6 is very rich with features. Best of all, you can build distributed objects in different technologies in the real RAD (rapid application development) way. To my knowledge, this is the only C++ implementation that enables you to build C++ applications on the fly, just as easy as with Delphi or Visual Basic. For programmers who are apprehensive of C++, I would recommend learning C++ using this product. I paid exclusive attention to three main subject areas of C++Builder 6:Windows application development, database development, and distributed systems development. Throughout the duration of this project, I attempted to make the book useful for every type of reader—a novice in C++Builder, a programmer experienced with the product, and those who already have books on prior editions of C++Builder. The entire book contains 12 chapters.Some chapters are relatively larger than we normally see in manybooks. To keep the flow of my thoughts continuous (which is very helpful for the reader), I did not want to break the chapters into smaller pieces. I divided the 12 chapters into two parts. The first part presents topics onWindows application development as well as database development. The second part is dedicated to distributed systems development and a few miscellaneous topics. Thus, I present more than 200+ pages on several distributed architectures, including DataSnap,WebBroker,WebSnap,BizSnap, CORBA, and TCP/IP. I also created a number of example projects,which you may directly compile on your computer, either for learning or for use in your own projects. Most of the source code for the examples is presented in the book and provided on the companion CD. However, you may need to have the Enterprise edition of C++Builder 6 to work on most of the second part of the book, since it covers advanced topics. For a couple of reasons, I did not present COM/ActiveX-related chapters in this book. The main reason is that almost all the available books on C++Builder present topics on COM-related technologies very well. In addition,Microsoft itself is drifting its focus away from COM-related technologies since they released the .NET framework, which would force many organizations to reduce the intensity of their COM-based application development. Slowly, many organizations will migrate their COM-based solutions to .NET or other distributed architectures.

13,824

社区成员

发帖
与我相关
我的任务
社区描述
C++ Builder相关内容讨论区
社区管理员
  • 基础类社区
加入社区
  • 近7日
  • 近30日
  • 至今
社区公告
暂无公告

试试用AI创作助手写篇文章吧