1 D0 G0 o0 t6 E8 P9 M* A& ^ . d ^" D/ z* N) u6 X6 m6 Q
如果有什么看法,请大家在在线讨论中进行讨论。 ( U5 |% @6 z7 H- f8 K9 x2 s$ O. Q3 s
9 O/ \7 |& H; s4 E
+ c3 ]- \: [1 w- Y3 P
" e" K: w# M! K2 K! e
恶魔吹着笛子来 来自 苍天已死,黄天当立--c/c++的时代正在淡去 : 9 D$ J1 F- h5 u) `# s9 x. L1 \ + n* T* R! c q, W3 S
不要以为这个题目是耸人听闻,但就目前的形势来看c/c++是需要退出舞台或者说的婉 9 t+ D8 D i: P: n; q转一点是需要更新换代了. / A" R% Z4 _0 s+ Q
0 p9 C+ d5 @" T9 K! r5 W
我想在未来的一两年里,作为程序员等级评判的标准之一c/c++(不管是mfc还是bcb)将 ; } G% A& [; h+ I Z t; _会让位给三种编程语言,1.sun的java2.windows平台上的c#3.xml , {9 @& X) a3 q
* c. l) A% u- W% } {7 Y! e
为什么这么说呢,我认为最大理由是目前的应用程序正在从基于独立的操作系统,传向 - \( X1 k; s4 t" N基于internet平台. # P# H! k$ F } u- k- K 1 G) j- Y3 n% H) @# x: u 我们以前开发应用程序都是依赖于平台的功能调用,mfc,bcb都是这样.而现在日益火热 ) q( ^. f" y4 e5 e6 Z
的internet编程却最不想关心的就是某一个平台的调用,譬如说要实现b2b的电子商务那 ' _6 q. S6 f, R k8 F' s! B么就需要做不同平台的集成,如果我是程序员我最care的就是如何实现商务逻辑 ; \* }) d$ Q3 L; z
' e# t) r; w$ Z# F6 E5 b& J
而不是各种平台之间的通信和管理.那么我们最迫切需要的就是一种与各种平台调用无 5 U/ B& Q5 s( _关的语言,这中语言只注重程序逻辑的设计而不涉及平台的调用.而我们熟悉的c/c++却恰 ; I y' ~& d+ }恰不是为这个而设计的(赫赫这也不能怪c/c++在70年代谁能知道现在internet的情况呢 , [ E( T: W8 g0 R6 ^).c/c++的最初设计目的是为了设计unix产生一种介于汇编和高级语言之间的一种开发高 . r/ W$ x. m" K4 _' f
效而性能不低的语言.他要比其他任何高级语言都要关心系统的物理结构,譬如一直是毁 & x: x7 q2 y: H誉搀半的指针.指针之所以强大就是应为涉及了系统物理内存的管理.他可以使得程序员 # _3 ]; |, ?" `" l7 U( d4 A& c和系统之间成为一种半透明状态.但是就是这种半透明的状态让指针带来了更多的不稳定 , F4 ?8 K4 s; k2 Q4 u0 q8 }性. ; s3 h6 Z1 \) T! y$ m, m$ Y+ p
8 V* s" h9 A+ k. B4 f( }
c/c++在面向Internet的编程中却无任何优势可言.跨平台的电子商务软件最害怕顾及 ) H/ d2 A% m, n8 Y* ?
各种平台之间的天差地别的系统调用,最害怕时不时的由于内存泄漏而crash.c/c++的优 / |2 S) c0 U' m. N6 q
势在这里却成为了劣势.即使在windows平台上开发基于windows dna的solution ! V9 |# ?% n" I5 w
' u I9 [: f8 Q. M4 @& d
用的最多的还是vb做的dcom而不是vc的atl做的dcom,因为c/c++虽然高效但是太容易 ; p( S+ T) Y& P/ a
" ]9 d* R v9 {2 k u4 x3 f 出错,如果不是很小心的释放内存nt很快就会资源不足. 4 x$ I- `% K/ d% C 5 U% `, T9 s' S# M+ a# w' X, a2 `
java就是最先看到这种情况,他用jvm实现了平台无关用内存回收实现了稳定健壮.但是 . o1 o. R; ]: Z. ?8 q9 m: O相当多的c/c++程序员抱怨java太慢了.的确即使到java2速度仍然是一个大问题.我曾经 # j' } q& C7 T/ f% I! z1 _是一个c/c++坚决拥护者在许多论坛里和java程序员打笔仗.但是我逐渐意识到面对与in 2 \* X: U8 K/ f$ Y8 B9 H' d8 b
ternet平台而不是特定的操作系统的时候java的速度问题往往是一个小小的瑕疵.我们可 5 d9 V5 ~) K& V$ v3 O
以想象那一个电子商务网站会用我们手头的pc做服务器,他们不是sun的e1000就是ibm的 5 T! c. ~% L( T4 B& s% f- Xrisc6000.在这种平台上java这点速度问题只是a peice of cake.程序员只需要专注与商 2 `. O$ {8 d( @& c( R ~9 O8 i
务逻辑的编程,而不必要关心数组是否越界,对象内存是否释放更不需要关心是不是unix % t `$ I# K/ Q9 Z% \1 d和windows的系统调用不一样. ' M$ d. y/ u. a' ^2 l# { w- A $ \5 \; k& S' R 微软的c#可以说是一种java与c/c++的杂合体,他可以回收内存,可以平台无关.但是 / i; H( m3 m7 f! E3 V% A & c5 ?4 ?5 L/ j) @ 他又可以实现一些java没有的功能譬如在标记的程序段内用指针自己管理内存,可以实 9 R' X5 }1 I6 Z
现操作符的重载等等.为什么要这样做我想也许c#还肩负了一定的面向操作系统开发的任 4 M; y' R. o- [. z务例如winform.他基本上的思想和java类似,但是实现的方法又不一样他不通过jvm解释 : [9 Y' g4 d! B/ r
中间代码,而是吧源代码编译成p代码然后通过CLS库和JIT在平台上及时编译为100%的本 0 V9 `2 C; ~3 V H7 V1 h地代码来执行.他的pe代码是独立于平台的,但是cls和jit却根据不同的平台而设计.因此 2 M/ q' Y5 v7 l& |+ b. Z( m$ K! p
c#的平台独立有点类似于c/c++在不同平台上的移植使得c#比java来的更快.而且微软还 $ j7 I2 ?! S! W" M ]/ y* i许诺cls和jit不仅针对c#还可以针对任何语言譬如pascal,smaltalk,basic因此将来有可 8 q- v3 |# D" c, @! g
能所有的编程语言都是可以平台无关的(ms真是毒,所有的语言都平台无关java还有什么 + j8 q: `. z8 y# T优势呢,据说ms正在开发基于pascal smaltalk的asp+). 1 ~8 F0 p! n& H- t ' k% l" q9 H3 i$ ]3 U a6 w+ B xml很多人可能认为与html相类似的语言和c/c++,java,c#完全不在一个档次上的语言 % V( p& w; z) D* d.其实不然.我们知道不管是c#还是java都是通过统一地层计算来实现平台无关.那就必须 6 u& Q% `! E% h' s6 Q1 c% r/ v在性能上付出一点代价.而xml却能够实现不同的语言之间的调用.譬如说一个网占用jav . i- W J. M) k/ Na用bean实现一个出货功能,另一个网站用dcom实现一个入库功能 .如果这个网站需要实 9 e0 A/ J1 h6 p现b2b,用一般的方式就是在他们之间写转换程序.而xml通过标记语言来描述各自的借口 7 q0 v P ^; [7 s- p# X: G
特性.两端通过解析xml文本来实现互相的调用,无需任何中间转换程序 - h' N% ]7 n0 I* A% O
' |3 l- z6 o" A7 K7 H. A
只要一张xml文本就能实现bean和dcom之间的通讯(要说清楚其中的机理,需要很多xml ! g! w. h1 {" v" t9 x, r
概念如果有兴趣可以到msdn.microsoft.com/xml或者<a href="http://www.s3c.org" target="_blank" >www.s3c.org</A>去看看).目前ms的.ne & R6 P- V# p+ f- Y/ M# E
t中最核心的技术soap就是完全基于xml的远过程调用. + W7 x# i) e- Y- D6 ?# y0 @% l8 O: O ! }* T# Q$ \2 B4 D! ]% f 介绍了那么多可能有点跑题,其实我最想说的就是21世纪的程序员应该从面向操作系统 ' W$ J' c8 M) W" L( u, \
的传统方法中走出来,学习一点如何面向Internet平台编程的技术和概念.不要在无畏的 ! B" i! b8 P) a5 }1 z9 H3 A
那种c/c++工具好之类的地方争论.我想不出一两年不管是bcb还是mfc都要淘汰, 4 L7 t3 e" @6 n# X8 }/ X# t5 H& c 2 d4 \- \/ D, b6 j 到那个时候要争论的不是bcb好还是mfc好而是c#好还是java好.至于xml那是不管sun和 % I- z3 i0 k% m. T0 o
ms以至于世界任何大的IT公司包括Intel,hp都在奋力研究的技术,不学习可能就要被淘汰 9 I: k+ C; n* i9 r- @/ H* G3 |: c
.至于c/c++可能就会沦落到现在汇编的地位在某些系统效能敏感的地方还能见得到. ! Y J; s! R0 t3 j6 d4 H
8 ~7 S F& P6 ?# V! U
如果是编程语言的初学者那么我建议学习java同时关注c#,他们首先比c/c++简单没有 |+ D2 P0 B% H& i- V8 T3 {3 `
复杂的宏,指针,摸版等等让人摸不招头脑的概念.而且是完全面向对象,比c/c++的半调子 # {/ B, E" h5 @ W3 A面向对象清楚的多好学的多.(我推荐目前学习java,毕竟c#还没有发布而且刚发布的bet 2 l2 \1 N, v. a; w
a版的编译器要求高的吓人需要win2000 adv server没有128M内存的别想跑.话说回来c# ! s) Q3 v0 ?2 H( o# V9 E
和java一摸一样没有什么太大的区别学好了java将来的c#将会信手拈来) 3 ~; \' T Y. |& v: ?9 x
& A z: M& c! I/ i3 W; Y0 K
对于目前的windows下的编程者来说学习mfc的价值还是有一点的但是不是太大.至少可 ' A3 \) |6 A1 Y8 |, h3 J
以熟悉windows内在机理.但是我还是推荐关注一下c#将来的windows.net都是基于c#而不 + T# E$ p, E. i8 W3 s3 K是mfc.而且c#要比mfc简单的多实现一个同样的windows桌面应用c#的开发速度是mfc的两 + x( e2 k% f* \5 d到三倍而且几乎看不见性能的损失. visual studio 7.0中 vc将是一个次要的开发工具 $ w& W5 o+ [# z/ p R
最主要的开发工具就是c#和vb7.0.至于borland我想是不可能不跟着ms走至少windows平 : u$ ?" N3 L' B( P% W8 w4 L台上是这样说不定明年就有一个c# builder出来作为borland的主打产品而不是c++buil - I) @) Z4 t# [; c* fder了.说一句玩笑话wenny说不定很快会把这里变成<a href="http://www.c#help.net" target="_blank" >www.c#help.net</A>了 9 _ f0 z0 ^$ Y/ G5 d3 @' g: ?
1 G- O1 s3 {- u5 d( T% P/ @+ G! y
' [) f4 ?( A/ F- P3 | * R( f2 f! C: d8 A6 X2 X
, H9 v5 |& S2 d/ j5 e' D
. I. a( r! d' p8 X zhangxiuyong 来自 <a href="http://www.ucancode.com" target="_blank" >http://www.ucancode.com</A> : 6 ]& z- x k1 w! ]8 t
* J3 L6 u: ~, r: y2 ?+ { 其实我认为,对于Visual C++本身的理解不是向你上面谈到的那么简单,Microsoft ) m8 l }' X7 b, c
在开发Visual C++的时候是希望为其开发人员提供一个可靠的开发平台,便于用户可以 7 A. k. A( {, M1 f
为Windows上面编写各个方面应用程序,包括:数据库应用程序,硬件驱动程序,网络程 $ m8 g* C* E- P序,多媒体程序,游戏程序等等方方面面,试想如果一个开发平台要同时完成这么多个 7 U* [8 `& i [* k' _$ [
方面的开发任务,是需要考虑多少的问题,因此Visual C++在设计的时候就考虑了提供 5 H6 o& f" I, T1 A5 n7 t4 m9 c L, T v一套类库而不是直接提供黑匣子式的开发组件来完成开发任务,提供的类库MFC具有很灵 5 }2 W) \! m3 E6 e; s+ A% W活的设计结构,以及良好的继承性,同时配合DVS文挡视图结构来组织程序开发,虽然我 6 t& t0 y, ^ C们承认利用VC开发程序(数据库方面的程序)没有其他的RAD开发工具来的快,但是如果 ( R5 ?* ?3 l2 H1 ~* t/ z3 b, ^- ]
你真正利用VC来开发的话,你会觉得你不会去选用其他的开发工具的,对了各位听说个 4 S, j" z) C( ]6 B7 Z0 A# w
多少开发人员是从VC熟练的开发师转向VB,Dephi的开发工具的吗,当然DVS结构本身也有 ( C \" y4 k& f: X/ H4 K5 Z" y
其很大的弱点,如很难重用。同时在CView中再嵌套CView的变得不可能。不过对于开发 & K+ Q# @( e1 N: K5 s3 ~9 A
中小型的程序(代码在50万行以内的程序却是可以的了)。对于特大型的程序我想最好 " Q6 h, R% a1 ~& z可以借鉴一种新的技术叫做MVC的开发技术来组织你的程序吧。好了各位此些文字,仅代 9 e2 L9 j G# b1 {# _: P: w; a
表个人之言,如果各位感兴趣可以到:http://www.ucancode.com上面看看。 . B3 b/ o3 w& y; [/ L x
: ]% }. s4 p2 @. b2 I
zhangxiuyong 来自 <a href="http://www.ucancode.com" target="_blank" >http://www.ucancode.com</A> : * D- x' b! l; R0 b( s0 A / ]* l9 ^: Z5 a) s' V 其实我认为,对于Visual C++本身的理解不是向你上面谈到的那么简单,Microsoft S# q+ Z. n- @: e/ q8 S, s在开发Visual C++的时候是希望为其开发人员提供一个可靠的开发平台,便于用户可以 - E$ M9 K/ m& Z( n" i" r/ Z8 ^
为Windows上面编写各个方面应用程序,包括:数据库应用程序,硬件驱动程序,网络程 3 y- ^- b8 q; _, t" t序,多媒体程序,游戏程序等等方方面面,试想如果一个开发平台要同时完成这么多个 9 @7 l9 C. w- \8 X* z8 x8 A
方面的开发任务,是需要考虑多少的问题,因此Visual C++在设计的时候就考虑了提供 2 }( s5 b2 i P7 Y一套类库而不是直接提供黑匣子式的开发组件来完成开发任务,提供的类库MFC具有很灵 . w/ h7 f; i. x1 }, }
活的设计结构,以及良好的继承性,同时配合DVS文挡视图结构来组织程序开发,虽然我 ( L7 F! {: G6 Z1 _# n/ g m0 M们承认利用VC开发程序(数据库方面的程序)没有其他的RAD开发工具来的快,但是如果 . E9 U3 i) f, d" S
你真正利用VC来开发的话,你会觉得你不会去选用其他的开发工具的,对了各位听说个 & g9 f/ H+ r# [
多少开发人员是从VC熟练的开发师转向VB,Dephi的开发工具的吗,当然DVS结构本身也有 2 r$ |/ ^; N% v! x9 g
其很大的弱点,如很难重用。同时在CView中再嵌套CView的变得不可能。不过对于开发 6 D, D+ _( @0 q# u. }2 {中小型的程序(代码在50万行以内的程序却是可以的了)。对于特大型的程序我想最好 " K8 Z9 }0 y* F+ [$ C" ~可以借鉴一种新的技术叫做MVC的开发技术来组织你的程序吧。好了各位此些文字,仅代 P" N2 Z+ q' L9 B O3 e
表个人之言,如果各位感兴趣可以到:http://www.ucancode.com上面看看。 ) q% q0 f6 H# L; i. B5 c* z
1 K7 f6 G, X/ {8 H; e$ E" \% i* ?
zhangxiuyong 来自 <a href="http://www.ucancode.com" target="_blank" >http://www.ucancode.com</A> : 1 {) r& A3 i# a5 g
k, z0 Z0 X- c0 k7 v2 F* I9 i6 c
其实我认为,对于Visual C++本身的理解不是向你上面谈到的那么简单,Microsoft % B1 R; B* m; h9 q. B# z- m* r
在开发Visual C++的时候是希望为其开发人员提供一个可靠的开发平台,便于用户可以 1 L& F' K' E6 q j- f1 f: p
为Windows上面编写各个方面应用程序,包括:数据库应用程序,硬件驱动程序,网络程 * `$ `# t8 L' d4 N序,多媒体程序,游戏程序等等方方面面,试想如果一个开发平台要同时完成这么多个 # h. E( [: e0 [
方面的开发任务,是需要考虑多少的问题,因此Visual C++在设计的时候就考虑了提供 % \6 g/ B' L0 B: z一套类库而不是直接提供黑匣子式的开发组件来完成开发任务,提供的类库MFC具有很灵 & C- B$ c6 W4 v% W! s- [
活的设计结构,以及良好的继承性,同时配合DVS文挡视图结构来组织程序开发,虽然我 . C- v1 @9 Y/ a; Z
们承认利用VC开发程序(数据库方面的程序)没有其他的RAD开发工具来的快,但是如果 8 F }7 p- f8 d3 h& q( W1 ]你真正利用VC来开发的话,你会觉得你不会去选用其他的开发工具的,对了各位听说个 5 i/ T% s: ^& R: J5 N5 I. b
多少开发人员是从VC熟练的开发师转向VB,Dephi的开发工具的吗,当然DVS结构本身也有 + |" k% r, {5 N. Y9 U
其很大的弱点,如很难重用。同时在CView中再嵌套CView的变得不可能。不过对于开发 9 D |6 M# t5 K; r( K. C
中小型的程序(代码在50万行以内的程序却是可以的了)。对于特大型的程序我想最好 : M- F+ R4 \% [# `. q
可以借鉴一种新的技术叫做MVC的开发技术来组织你的程序吧。好了各位此些文字,仅代 6 S4 A# A$ G) H- f& n# X表个人之言,如果各位感兴趣可以到:http://www.ucancode.com上面看看。 & A1 j( Q* n& e" g* d
1 D4 i( ~6 n3 l# g k- d; Y0 h wenyy 来自 <a href="http://www.vchelp.net" target="_blank" >http://www.vchelp.net</A> : & d2 s: G& k% y, }
( U: ~3 v$ p! L& G0 @ 我一定程度上同意 恶魔吹着笛子来 的说法, 1 G* ~% q- X- w1 D5 }8 H : y% v) w7 |# c) e
毕竟VC开发速度是比较慢的, 5 g( n& n4 j/ \9 W
% ?1 m" z' ~# c, _, @ k
而且硬件速度的大规模提升也为使用JAVA开辟了道路, , u- |+ Q3 p( L , T! o1 q- W: Z4 h
不过microsoft.net的目的是一定程度上改变MS的经营性质,和开发关系不是很大,但 ) R# K5 i# H! z. S U1 X是MS的一贯方针都是在平台上为开发人员提供方便, ' A6 O2 B+ B) Z1 K1 X 2 g" S/ v" m4 |3 `6 j 所以C#是为了.net服务的。 * A+ c+ K w1 [. U/ N . D# m: {8 e$ F2 ~
4 U- V0 X/ Q$ `; Y; b
此外我想我没有精力再搞个c#help.net了。:-P 0 w9 e! l$ U4 G/ U# q* Z( x + s' n6 V5 r- W- {
果子 来自 http:// : 6 p" J+ ^# j& X0 l4 X/ ]
+ P( _; d E& ~9 Q
"恶魔吹着笛子来"是比较“前卫”的一类程序员。我就听业界的人多次说过JAVA也是 ! B9 k# J1 |* j p* ]
/ i8 B/ U9 Q3 B5 o7 l \3 F
7 k. G' e: K/ g8 S$ B. C. Y 个吹得很响的东西,但实际如何,大家都看得见。至于认为C/C++开发工具(VC, 8 Z d3 G! R7 x. V( B( K: T. p 6 l- Y" n8 h& Z! Z- d0 C5 b) _1 A
BCB等)会在一两年内退出市场,就是无稽之谈了。 b; n H/ N& C" X( M6 O4 Y
4 x+ u6 a: a# X9 v Wesley 来自 http:// : % h; W( ^! h/ D4 i
. B5 F& H3 K K% j6 C2 s& U K% U/ B
恶魔吹着笛子来,你的观点很有启发性。能不能写一篇或推荐一篇剖析、比较Java开 : t1 Z2 r+ T; U1 P: V! s
发工具的文章?比如Visual J++, JBuilder,以及Symantec和IBM的对应工具。(可能和 4 C" h* c# b6 H$ I5 w+ P) {, t$ A
本站的初衷有些不合^o^) $ ~* Q9 H4 s# b g* h
6 i, z$ E4 L& S! S) B! @6 Q: j5 @7 A% E
LeoCN 来自 http:// : & k: c& l8 }/ i( x; G ?9 D* U " A: ` ^6 Y$ A* r9 b7 l It's not a time for us to determine which language will more better! 0 F2 F1 Z# [$ S2 y) r
; o5 N) z9 t2 a/ B8 L% Q
in factly,In China,too many corporation just writting some codes for : E6 b0 g$ q& T9 v/ R5 @
6 X5 f0 O5 K0 o) {. x enterprise's MIS,OA,ERP or other application.It do not need so speed + a) s3 m! h& t6 \: p. u6 L 8 l, T/ Z v4 N" h
and do not need so good original code. just want more data,more easy and m 0 d5 o' Y; | w& vore quickly. 9 M& F: |- J# z! h; t5 Z# b
, G: U% v3 T) ]
so c++ is not a choice in such enviroment. and u know,many codes we write 1 {5 S9 r! @, F" z
today will be useless.and there r so many easy tools such as VB . S% ?$ o- [8 ?0 P5 d* X
/ h& \& D" `- g! Y1 Q+ Q3 H6 W% J
for windows designer, Developer/2000 or PB for database,Domino Designer fo * u! \) ?8 F( _9 ]: q ?r OA application,why c++??? + Y$ B( j6 [* b! H' Y, @0 i) V - Q7 d7 X1 a. G7 |8 ?% t
in DOS mode. i like Turbo c2.0, with it and MASM i can do everything. # ~( o& q+ m3 n& \: E7 K M 5 o J3 L& T1 y0 H- L but now i hate c++, it has waste my time! my corporation do not need ( S" B7 o0 }+ `5 V
4 F& ^* B/ a* p; W s8 _ c++,just need java,xml,php,pb,vb,delphi,developer/2000,domino designer etc 1 q! b* ^2 G% s
. ! P2 G) ?+ X5 r* M( o7 S9 g+ C
$ r" Y1 W' P% u" n, H so, a tool is just a tool,if the advantages in some aspect of the tool 2 Y6 ^ C2 z! B! Q& w
8 S2 v; {- u7 l1 o u needed. it's will be a good tool for u. others it can bring u unfortunat * { g1 V4 A/ Q: e4 Lly! + l5 `7 G0 a( R: n
& N, \2 |6 g. z7 s/ \' b 恶魔吹着笛子来 来自 : # H. T2 \0 T& g2 @! X y
4 D3 P/ U8 `1 m7 |+ W& q
果子,国内的Java应用不到10%基本上是ms的天下.这些可能是由于中国软件业规模太小 * S6 ] v5 u3 x+ i% ^' }: q1 [7 p的缘故.而在国外40%的商务系统的开发都是Java,c/c++不到10%.譬如BEA公司一个有3个 , H. B) r" ?* [; G Y
java程序员创立的公司开发了第一个基于J2EE的Application Server---weblogic.BEA公 0 }6 j0 j3 F$ o }& r+ t* }: E
司依靠weblogic在短短4年里成为世界第四大软件公司仅次于CA公司.可见JAVA的功能是 # @& n+ x- K7 W% D2 k, h' V( |" T
如何的强大.微软的.NET的负责人说,你们想要知道.NET是什么样子,那就去看看JAVA.JA 7 E* G2 ]0 `. M
VA是什么样子.NET就是什么样子. + B- y/ o& S, {8 { a; X7 ]
+ [5 G; O- Y1 p7 F" i+ W. G3 _5 u
- u! ^2 j- j! j* y; N ) x" }9 _, w/ Z% m2 z 恶魔吹着笛子来 来自 http:// : % V8 U0 @0 p5 ~5 a5 k
2 x* V5 L) K9 m$ u J Wesley你好.关于Java开发工具的问题.从我的观点来看,目前的Java开发工具没有一个 |5 U% V; ^" b& D/ h. A6 l4 L8 m
令人满意的.最主要的是,在技术上考虑的太多,却不像MS的开发工具考虑到程序员的方便 / R% W6 ?( x; Y1 ^% G: ^8 l7 }(vj++是另外一会事情我后面会讲). 0 v6 g9 U. v6 t( ^5 u" E1 H: u5 L$ t5 g- t , E- Y# C1 \* w3 k; \! T 基本上流行的是sun的jdk,ibm的visual age for jave,samtic 的visual cafe,和bor % ?, E0 ^& Q. S+ P9 U' oland的jbuilder(vj++基本上没有什么人用). $ |) z1 y- k* k* c) h6 C" r( d" U
2 i; t, M; s- o+ B( H$ a
在这几个工具来讲,jdk是老大哥,但是仅仅是一个command line compile.在某些方面 1 w+ c$ ~- c% x& a" j用ultreditor+jdk会比较方便,譬如你的机器的配置比较的低(memory<64M).一般来说,几 " ?/ k3 g2 t) S% @* ]
乎所有的Java工具需要的机器配置都比较高. 1 Y0 F; Y5 m, _: I - l: g/ b2 M/ [* ~: y1 c ]' t
visual cafe是第一个可以使用的Java IDE工具,我当初学习Java的时候就是用这个.它 & F( c! z: V7 H) `, D6 l* g( F
的配置要求比较低.一些比较低的版本譬如1.5 2.032M就可以使用了.但是现在最新的版 9 j3 N- G. V) t8 H
本5.0的要求就比较高了,可惜2.0以后的版本没有用过.cafe的IDE开发也不是很方便,懂 / G) X6 m' } s2 R% F) T! r
一个窗口西一个窗口比较的乱.而且bug还很多.有的时候trace到一定的地方 : Z2 w# d) k) L! C
1 X( ]+ a Q/ `8 J4 n 就会crash.samtic是一个系统安全公司不知道为什么cafe却那么不稳定.而且从技术上 2 |& f9 f9 E3 C( Q- P来说到目前为止还没有完全支持java2.更不要说j2ee了.从帮助来说cafe的帮助基本上还 5 Y- Q4 R# y8 i$ t3 j
是jdk的帮助没有什么特别的地方. ' C- O1 I. k' g$ d7 x% v6 R4 t0 k: { ) p8 W/ j ]" F4 z# \! L- A( I4 b
IBM的东西往往是吹的比做的好.visual age很复杂功能也很多.支持100%pure Java和 5 R: W% D) @# T0 r6 UJ2EE.但是使用起来不方便,当初为了设一个class path找了半天的help都没有结果.后来 ( V# l$ ?7 S8 D: a6 ^6 M& p V听别人说要在nt下面设置环境变量才能成功.而且与其说是visual age还不如说是comma # @' j& V! X6 I T6 h, Q( e% rnd line套了一个windows壳子.做application还要自己写layout代码更本就不visual. 3 ^% ?9 n* m4 [4 c: e1 q" Y 1 H2 I: v7 Q6 J9 k: ~4 D0 K Jbuilder是我目前遇到最好的一个,它的界面基本上和delphi c++duilder差不多.他是 6 _ f6 w5 p. W+ ~+ O" k第一个真正的java的rad系统,第一个全面支持j2ee 13项Java技术的工具(bean,jsp,rmi ( | S3 G: H- j& S3 z% B/ K都实现了).100%的pure Java.相当全面的help document. 9 O3 d" ~1 ^3 \) J ; b: T3 n$ G) n
但是他最大的缺点是系统要求实在高,没有128M别想用.64M下面慢的像乌龟,help更本 1 D& K! R# w0 W. _3 E/ O% N: L& E不能开(它的help都是java写的64m下面打开help慢的能够看到一格一格awt画窗口的过程 & s6 b+ i% I7 B! L7 L. k
).但是不管怎么说他是一个比较理想的系统. + L3 O- G+ t, n ~! W# ~0 a+ v
( N' `2 z* n; @/ a3 g 在工业控制中,直接对I/O地址操作,就要用C++。 S2 t2 e( ^, t8 z* e5 \7 v
0 H6 ?# R, b4 _ S, d" { 恶魔吹着笛子来 来自 : d* K, H+ }4 G( W5 R# }5 e
! S+ A4 `& m+ }9 q2 l
俺有一个同学毕业设计用VB做单片机。你这不是在讨论问题是在抬杠。 4 p* I' u+ G2 h. a
' f, o9 u+ B$ f$ u- Y+ [. c4 G
wenyy 来自 <a href="http://www.vchelp.net" target="_blank" >http://www.vchelp.net</A> : " e# \/ N6 F' s# \7 Q j # u& q4 O8 s6 Q2 R1 g
我想一种语言并不会因为其他语言的出现而消失, + d- F+ J0 F* P2 J" E + F$ g- p F+ }7 k$ L# E: |
比如说c与C++,C++与C#的关系。 . R1 K4 Y6 Q, v6 W
! }9 X# L% n' R+ S0 N3 E6 A' I
所以我想讨论问题时首先是要排除敌视, 6 J) r! E: g& K1 i. s
0 S2 V7 i" s; i" K8 S8 \
然后才是透彻的分析。 2 |7 X7 M8 |+ b, K2 k5 b. p 7 @% M3 m9 [8 P. { IT世界不光只有网络,还有其他很多。 & ^% J) ]4 j+ w7 i4 E 3 t* B, K% O) n8 ~. x$ O& p 所以某些工具在一定范围内适用是正常的, + O- [) i4 P2 P' S+ `! ?' @
9 C4 E. I7 b0 k( |% @
其实在国外, / G% q; K6 v/ N2 G
- y5 ]1 g8 G- ^3 b2 ]/ f/ [
SERVER端软件大都用JAVA,而CLIENT却没有多少用JAVA, 8 @$ d! s, r1 T0 t5 V/ |
* ~0 A) s+ }" E) ?5 e5 s$ F* _
这和速度有关,当然也与MS对JAVA的态度有关。 5 V$ \8 \$ D% z5 N% |5 n
5 n9 \6 I2 {7 x: Z: ~ ; O& j$ }* f: r& Z 不过我一直认为C/C++不会因为JAVA的出现而消失。 4 ?% Q7 @" ], D9 ~- s+ ^3 N- D$ t9 f + K2 u% R* k8 F' L
就象COBOL目前为止还在使用一样, # L3 n8 m% p) ]& @4 B
7 c: s# Z$ _5 k; X. w2 O
2 P" ]# S Y% ~' S+ G2 L6 k 不过以后会有愈来愈多的解释性语言出现,因为解释语言比编译语言的兼容性好,这 - S) K0 o w/ U7 o9 D5 v0 V是不得不承认的。 + H, u& T( ~8 y7 G
W$ N6 ~5 |0 T0 m
恶魔吹着笛子来 来自 http:// : ' u9 G$ I4 |/ x; Z5 u
8 K, {8 B' a0 W" F
是的wenny.也许我说c/c++的消失有点夸张化了,但是实事求是的说.java和c#的出现 6 I" o3 d9 ]6 b5 N* A0 L! O, h v$ K # T# z. D% _" g1 w" ]' ?% N" U! O
c/c++的升级换代是在所难免的.对么. , f' i5 Q l& x- J' A* n
4 V3 G$ T% l$ _' k, [" m1 C
恶魔吹着笛子来 来自 http:// : 2 j8 y' p7 ]1 f: K
4 s/ P! Z1 ?' r8 ?( c1 r7 S0 F
而且我一直认为java和c#不是另外一种语言而是c++的升级.就象是c到c++的升级一样 1 D0 D% A. b' m3 L% N& C
.对不对. ) y( W- Q0 d6 O7 c; z8 w* J G, P
+ @+ i3 S! }$ n Q" g xcc 来自 http:// : 5 E- X u' X p& }/ O/ n( @ 3 |9 K" M; f; {$ G' `9 H0 q
同意恶魔吹着笛子,你简直是我的偶像,顺便贴一篇关于C#和.NET专访 ' j' ~$ @" \$ U5 I% i5 [, t. b % h% W1 K9 O, | NET and C# Questions with Jeffrey Richter ) {! G9 A2 ~" O) B7 |% L& b
9 k! w- J6 Q) D
In the weeks after Microsoft made a huge splash in the development communi ' O4 z% u; f; T4 d
ty with their .NET and C# announcments at the July 2000 PDC, Jeffrey Richter , I5 k" _. V h: N; s/ M accepted our request to field 20 questions from our readers about these new 9 Q. Q5 @' `/ P3 [- m$ P7 g& ~
technologies. As many of you already know, Jeffrey is a cofounder of Wintel # p' G2 L7 }: U, p
lect, a company that specializes in Windows & Microsoft.Net training and deb + r1 l# a5 y$ mugging. Jeff is also a consultant at Microsoft working on the Microsoft.NET ' i# u; L1 N( ]( m; N
Common Runtime Language (CLR) team in which C# and Visual Basic 7 applicatio 9 F) A; \$ h, [0 r
ns operate. Below are the 20 most popular questions that were sent in and Je - B4 Y6 s2 r+ J1 Sffrey's responses. % c9 g) z3 u3 [0 x" f( j7 @1 c J0 ]* L5 W) O- F o3 V3 q For Visual C++ developers everywhere still trying to get a handle on all t 7 q- d( i# g! M4 @6 i. o
his: Thanks Jeff!! $ b, A* y# y. {) \+ n" N6 s ) D+ ~( Q6 i" e' W8 j 6 h3 _3 X5 D, k+ Z% Q( Q E Question #1 Is .NET a runtime service or a development platform? 1 k+ Q" a1 V& e" O+ o 1 e1 z2 I3 r$ F; h. z. S
Answer It's both and actually a lot more. Microsoft .NET is a company-wide 4 w) |: t7 Y! N8 ^/ o6 y6 P initiative. It includes a new way of delivering software and services to bu ( X2 f5 @) q" i$ e; s m- u$ k# j
sinesses and consumers. A part of Microsoft.NET is the .NET Frameworks. The 2 a& m( X" f3 P' t" e5 A2 I
frameworks is the first part of the MS.NET initiate to ship and it was given + d, M6 W9 v1 o/ E, L" o& G: e
out to attendees at the PDC in July. The .NET frameworks consists of two pa / L! ]* H3 _9 i. V& Mrts: the .NET common language runtime and the .NET class library. These two ( S; h% Q( f& s9 ]2 R- I" L( C8 ^
components are packaged together into the .NET Frameworks SDK which will be # ^3 G0 h- f( x* }5 K! E" m0 L3 Aavailable for free download from Microsoft's MSDN web site later this month. 5 ^9 t1 d& i9 q0 ?* j
In addition, the SDK also includes command-line compilers for C#, C++, JScr ; l+ L8 l) w2 I3 A' f3 y1 |1 ?ipt, and VB. You use these compilers to build applications and components. T * S4 \3 ]7 x9 c. z/ Z! a
hese components require the runtime to execute so this is a development plat 0 ~8 B) Z3 R$ O) v5 `6 qform. When Visual Studio.NET ships, it will include the .NET SDK and a GUI e " A2 t: l9 C6 D% A! T7 ^5 s7 p) Wditor, wizards, tools, and a slew of other things. However, Visual Studio.NE - q) ^5 y9 h6 D6 g5 f$ dT is NOT required to build .NET applications. . Z6 J* c! R- Z) U4 _3 c6 D
# ]2 w1 [0 a9 ?* m4 B4 N- r# y
7 {. G, h8 h. L" D$ \! k7 E% \8 e' z Question #2 How likely it is for C# to become a general-purpose (meaning: & D' l9 i* \8 s) i3 R- }. T- i
not MS-specific) language and if so, have any other vendors committed to pro / W; h% {% J# c
viding compilers on any non-Windows platforms? 6 W0 J# x) t% e" Q 8 ]( O3 r3 f9 Y$ M {* T; X! Z
Answer It's hard to answer this right now. I have been programming in C# a * v+ E7 v7 U1 C: o0 M$ tlmost exclusively for about the past year and I love it. It only took me a f 8 |; D' s: b, B4 dew days to learn most of it since it is very similar to C++. It was designed : r: i* j9 Y" ] to compliment the common language runtime and I think that it's unlikely to $ L0 v {/ @' N |+ W# r6 x% [ gain much momentum if decoupled from the runtime. However, you never know. " u) _5 ?. K& k C) V( kMicrosoft is submitting C# to the ECMA standards body so any company will ea * x! J! @+ e7 N+ i3 T; ksily be able to produce their own C# compiler however, without a runtime, th # ]/ N/ h0 W0 v% H0 z) fe compiler itself is not that useful. I'm not aware of any companies current 0 R0 A3 ]% c/ ]# P1 A
ly working on their own C# compiler. Certainly, porting the runtime to anoth # m) N) I9 p$ L* x$ r' ]! ~& K9 j
er OS is no small undertaking. 5 w' Q/ k2 a$ i. N/ O; W. p
9 @6 @7 ^6 z. Q" N: C9 h2 } \! w% t g# _9 o
Question #3 Can you tell us specific practical problems that C# can fix be + }3 N% X6 q, T" Z( h
tter than Java? , S8 ^3 {( E7 c$ Q, \* C , p: O* P6 h+ {+ D Answer I must be honest with you: I have never programmed in Java. I know $ ~8 U4 S5 B. E! ^
what C# offers the C/C++ programmer: simpler syntax, components that seamles " k1 r# K1 ? h5 x- [, O' H
sly fit together, type safety, and so on. Other people should be able to add + O t5 `' k5 g1 h; g! c( H! l( O+ T
ress the C# <-> Java comparison. ! ]! e: ^: Q b \8 p & ~2 U& F! [7 S% ?% D) ?& u9 K ' w4 x1 \) d" v' K& l( h5 A Question #4 Will ADO+ be the preferred and most efficient method to access & r& u: D( _6 R
databases from C# or will it have it own (or .NET) class wrappers for the O 1 M* t- k# C0 p: _0 G6 E
LEDB API? 7 W. L9 g) |0 C# H4 ^ - c* j2 p. A8 H. a, c
Answer The .NET class library includes a System.Data namespace with many t " ]# ?- s% W6 S9 l+ a* l3 Nypes for database access. These wrappers will be the best (and most efficien 1 ~: f) t# r6 k- p1 z8 u
t) way for a C# programmer to access data. : L9 `0 V: k! z. j
# o' ?9 z1 r1 N* z. u5 G/ a6 [
% x. M! L; B% @' e& r Question #5 Can C# be used to develop Windows applications or is it soley 4 q8 |! D. ] e7 ~ P9 j
used for developing distributed applications? # N/ r6 J% d* T
4 p& X8 J& N: a
Answer C# can absolutely be used to develop classic-style Windows applicat 4 h& u9 x) ^3 R. B4 p
ions. Actually, this is more a function of the runtime, not the language. So # t w1 z) N, o% K) C, the runtime supports console apps, GUI applications, NT Service applicatio - x2 J+ W( \1 T: t4 }ns, simple components which can be used in applications, web pages and so on ! g2 s- H0 ~2 A! F3 Z
. You can't write a device driver but that's about all I can think of that t ! O" a4 Y, _% ]$ c" }+ q5 lhe runtime doesn't support. , E6 @( C4 F% m
+ a# U. e' q" E8 n0 p' _: ~- G
$ ^3 V8 y, q3 f) G1 m+ P Question #6 What is the C# relationship to WinForms? . r/ I- U0 D, g
4 D3 I$ u& h* K9 v( c1 j, z' ^
Answer Win Forms is a set of classes in the .NET class library that wrap W ! P' \3 i& v! F4 hin32 windows, brushes, pens, etc. Any language targeting the runtime (includ 9 v& w" j3 L2 N* l$ k) `+ ?ing C#) can construct instances of these types and manipulate them. This is # p5 e- Q/ @7 ^# }+ ?9 F u$ m! `how you would create an app like Notepad, Calc, or Wordpad. I know that Win 8 ], o; w- V: X PForms has similarity to J++'s WFC library but I also know that there have be 4 I2 x3 N+ L2 c$ c0 B$ X
en some major changes. & G1 L# l( l; D) S5 l5 G
/ G8 L" U# ~. W0 @
7 y5 M" O& ] y9 {
Question #7 Rumor has it that the C# language has been submitted to the EC $ [7 t& ~, Q) V7 @/ n( H
MA for ratification. Is this true and what impact do you see that having on - H3 N: X- o/ U4 A4 h2 C P4 {
other companies adopting it as a general language (such as C and C++)? 5 w- t+ I5 Z- o$ h; R( w0 Y
: Q; Z3 R; _" t, ^1 j7 z
Answer Yes, it is true. I pretty much answered this in question 2. 2 k; \& ]' B5 G. z' m
9 J# E% W O2 A6 }# {, E8 [ " n: o' D1 P* Q4 L7 D/ u
Question #8 Which will be the role of ATL and COM in the new .NET technolo / s. {0 r% ~. H
gies? 3 W O0 |! N7 c5 W5 | ! i! a! r8 N% ~6 d: u. N+ d Answer The .NET frameworks offers a replacement for many existing librarie , B2 @. y2 g+ f$ |/ N, t$ W; hs, like ATL, MFC, C runtime library, standard template library and so on. .N * u! L5 ~' _" Y* z1 W3 O( oET programming is significantly easier than using any of these older technol - g$ Z0 W/ l, _, z- Togies. For this reason, I suspect many developers will move away from using " u* U& l2 a1 G
the older technologies. The older technologies can buy you performance howev " p* l& a5 ?( ~$ v. y$ l
er; so, some people that are very concerned about this will stick with what' ) P/ A- A1 C7 z# hs around. As for COM, developing components with .NET is orders of magnitude & w0 K2 p7 P1 l8 k8 N$ @0 v/ c( K easier and the interoperation between components pretty much happens for fr 0 U: J8 S, W; E# ~1 H1 T, Lee. Again performance may be an issue for some. And, for the time being COM+ ! Y4 n% k: K1 }
services, like transactions, are not being offered directly to .NET code. Y # _8 I# f. [: D% }2 @0 n# H
ou can still access these COM+ services but .NET code must incur an interope ( N+ H9 T' |8 j: O; [6 trability transition, which translates to a performance hit. ' S6 q/ W; L% j1 p3 q. ]: W
# ?1 u/ ]9 K2 I& c! L& Z, }" z
* Y( o3 h( G. S a( \; S; ~
Question #9 Why was the templates feature not carried over from C++ to C#? 1 d2 F% r+ Q" S) s- t, B2 _
% j* r: G: G( x7 k4 {. b+ a: `6 s ( \/ {& c4 F( T8 H1 y5 x. P$ B" @
Answer Again, this is more of a runtime issue than a C# issue. First, temp 8 A: J5 _3 j( [% xlates are difficult to implement and Microsoft choose not to do the work for : _3 ^7 `! c3 H8 q% L Version 1 of the product. They may do templates or something similar in fut , I2 c! Y: R# c; @+ Hure versions. Second, since the runtime is a multi-language runtime, introdu * R6 C" e$ U3 Tcing templates means that all languages targeting the runtime would be requi * J9 Z( M+ L, T! ?# ]
red to support templates in some form. There are a lot of issues here that n 6 F0 ~4 j. p, N- teed to be carefully considered. / d2 L3 j0 y' N3 H# z g u8 q+ j U5 q9 b* S, A( O" w$ O* g% J1 ~
+ M& @% n. Q: P
Question #10 Will C# replace the pseudo keywords that clutter ATL COM code ! P5 q2 E6 V2 x% {! ~ with real keywords? Examples: OLE_COLOR, BOOL, VARIANT_BOOL, and DISPID_XXX ! u" `8 b. \1 z( ]/ A
XXX. 5 n8 _0 e6 X# D. u7 v" ^ + K4 }. i* B* I4 H Answer Absolutely, all types have new names as provided by the .NET class : @1 U7 O: y/ h, B( o
library. 4 [, b: H* i" _* ~2 p - |7 S& E; O' J0 h7 T2 | 1 ^( T/ _0 k) v+ H! |5 Z! |! i
Question #11 We've seen managed extensions, but aside from that, what futu ( G& \1 h: D4 \' T' p
re does C++ have at MS and in .NET? 2 q3 V. X, z; p" S! n8 [ 5 z3 O% D1 r! m: n7 p Answer C++ is unique in that it is the only Microsoft language that allows " Z8 F6 x6 ]; T the developer to write managed and unmanaged code. So, I can easily see dev : w9 v$ ]9 J* h5 h; J+ l( v" c6 w
elopers writing in unmanaged C++ for performance-critical algorithms and the 2 Y! d7 B& s( ]3 m4 v5 c* s- Yn using managed C++ for type-safety and component interoperability. I'm sure # c% d9 t6 d* a5 v! a3 Y" R
Microsoft will keep C++ going for years to come: device drivers need it, Wi 4 c1 I* W* T4 n. Sndows is built with it, SQL Server< Exchange, and other BackOffice products . X2 V% l/ U4 P# v" S/ S
will probably use C++ for a long, long time. n: ]9 T' d! x6 o' }/ i
; ~1 l5 l+ ~( C6 r ( S8 [# h5 M" T9 Q$ D
Question #12 If .NET supports ActiveX/COM, how will security be assured if 0 c* c/ D9 b- B7 j a C# application runs from within a browser? , |* F- B0 L9 x2 i; X
6 |% x7 \' z H9 r+ @
Answer The .NET runtime offers code access security, which allows an admin * R) e6 P+ C k9 O7 n4 X
istrator/user to configure security based on code identify. By default, any 5 V7 a6 ^' d9 K( r3 i9 L$ H* {/ ccode downloaded via the Internet or intranet is untrusted and will not be ab 5 E4 P2 n( \3 O" r. {le to access files and other resources. In fact, when I build a console appl ! {& C2 V2 Y9 q& U+ H$ xication and run it from a network share, I get an exception when it tries to 8 o% ^, u2 D; O( ~/ t
access certain resources. If I copy the same file to a local disk directory 0 N* P9 u! K$ l and run it, it runs fine. Code access security is integrated with the runti 6 J. T) S R( a q2 Jme and is too deep a subject to cover here. 3 G6 u. v2 `+ a3 N0 u 2 U& e$ R: n5 ~; B
# j4 D, k9 E9 {; |' r, i Question #13 With regards to the .NET runtime, do I need it on the machine # ?5 Y8 j6 b( n that I deploy C# apps on? 8 D' l( Y& v! e4 m% K# o4 j
, Q6 @- v/ P7 l" `
Answer Yes. All managed apps need a manager; the runtime is the manager. M - F0 ^; N: L: p @+ F r, Qicrosoft will eventually package the runtime so that it is freely redistribu & @9 c% J& w: R% `ted. For now, end-users will have to install the full .NET SDK from MSDN web ! `; g, n9 b0 O6 Y7 |: q6 f site (when available). This is similar to how VB developer must ship the VB % n9 |! j/ t! {7 R& K [5 l runtime today. 6 Z/ I# R7 `( ~ 6 |5 e+ k1 v P' ]
7 p. b" i4 [! X2 j& q
Question #14 There has been mention of being able to derive C# classes fro ) n+ {. J7 k% y' Q5 ]9 J
m VB classes. Is this true and where can we see an example of how to do this 8 P- ^! w Q# ~' w? X( V6 F3 {1 c; b6 F : V. |6 `% A+ C0 b% G" l, W
Answer This is true. In fact, any language that targets the runtime can de + y2 e4 E# {8 \" e* B, _/ s
rive from any type created in another language. Also, the Visual Studio debu $ J' N9 N" E' f3 B' z8 n# s7 ^gger fully supports debugging across languages. Each entry in the call stack $ {* [4 P4 w' C, Y6 D
window shows the function on the stack and the language that the function w , Q) M# r% s& s4 [as written in. This is very cool and got a round of spontaneous applause whe ; h Q: {) E i( {, On shown at the PDC. There are samples in the .NET SDK that demonstrate how t 1 ?2 s- _& l1 l# Q2 a% i+ p2 Bo do this. It's really quite simple. Actually it just happens, there is noth 7 {: }! H/ n/ ?2 M4 s, g6 s
ing for you to do. You can also throw exception across language boundaries a I+ g# R( t' G: q, | A) Bs well for error handling. , ?' f9 B" s$ }& d* F
$ c5 |2 H/ @9 n8 w A
0 ~8 r ?! y0 j7 P1 h Question #15 Can I derive a C# class from a C++ class? If so, how? * B# \( e- |0 ?; C; f+ F7 e; x
6 H( R2 ~ ]5 B8 B6 v
Answer Same as the answer above: Any managed language can inherit from a t 5 @" v; a8 h! ?
ype in another other managed language. If you use native C++, then you can't 0 q; r$ c v, m7 L L do this, however. / m" X3 A( o* g: U: o) [ " m9 C) Z0 @8 ~: O" F
( N9 j: H8 u! a. v' N) T Question #16 Will the new version of MFC have the option of working in a m 6 Y- Z2 S; j. s2 G, y! g# W; z
anaged environment? * W9 k& U' N- y Q
L8 q+ Y, }, r$ Q5 _/ t5 [- b
Answer I haven't been tracking the new version of MFC but I'm pretty sure / C1 h) |, C. [& }; k
the answer is no. MFC is all unmanaged just like it has always been. For man ) c* ^! c. Q; F- _aged applications, Win Forms is the window manager that people should use. ' X2 \- r6 Z( q9 [ 7 W8 b- G2 P- X6 x! }" j$ S$ P( [
3 m( d2 B+ G" N( @! Q9 {3 ?
Question #17 If the new version of MFC will operate in a managed environme , R& [( F* l" r8 l- L' ? k
nt, will it have the option of building desktop Win32 apps and not needing . * F( r0 q0 ^6 Y" q0 c- W
NET runtime support? T- |9 e1 Y. W6 G! s- `9 m/ X 9 i, f+ w$ g1 t" d% m$ Q5 Q2 e Answer I'm pretty sure MFC is unmanaged and will never require the runtime " ?; g* @5 W& B4 L b
. V u5 L7 b! [; L- k. T# a
) p+ _1 b, @, G# w8 d& t * b$ _4 |' n- Q3 ?2 s Question #18 Stroustrup has been quoted as saying "I have not expressed a 4 X; e1 x1 _1 l! |% [0 J4 jtechnical opinion on C#, and I don't plan to do so. C# is yet another propri 7 Z3 E$ N$ L0 x# K# L# f
etary language specialized for Microsoft's Windows system." Do you agree or 1 h2 D$ f& C% I- q+ Qdo you think C# is more of a generic language open to other platforms? + b: V( ] B/ ? z, _; L # N$ Q; H* }5 ?- v
Answer C# is a language designed for the common language runtime; not Wind . l+ E! {+ G* b8 u4 i/ s
ows. The CLR can be ported to other operating system like Linux and Solaris 5 u3 K. [6 s3 R* U$ u$ band if the CLR is there, then C# will probably be there as well. In the gran 8 z4 `: _1 ^" b
d scheme of things, C# is not that important or interesting. It is a syntax ; z2 `5 Y" t4 r- C* U2 l
checker that spits out intermediate language consumable by the runtime. You , @0 v7 T* w/ D4 C/ Hcan love C# or hate C# - your choice. I happen to love it and think is the b / F/ K$ s) ]' d$ jest programming language for the types of applications I write. 4 ?) i( a' t( t" Q. K4 T2 w% F
) i# L" z/ g$ G& c( a
8 r* U- @# a! @5 p
Question #19 I heard a rumor that VB7 will allow static linking of the run v+ k1 i7 f+ i o) u. a$ _9 `+ atime, like MFC. Is there any truth in this? If so, will C# also be able to c 4 F% S2 d4 ?# U; z$ l' q
reate standalone apps? : K; S) w: [4 H9 {4 M; c
2 ?9 j7 Z; k8 }, w Answer This is absolutely not true. No language will able to statically li % X$ H0 k z6 t knk to the runtime. ' h: y/ S8 c2 o
, Z7 H U6 ~# [$ S) l
7 w* z$ H+ G5 A9 ]2 X Question #20 Does C# still use resource files? If not, what mechanism is p / r% m. J6 A9 W6 Y. _rovided to allow for localization? & g u, b( M: m% p$ w; C' y
; ]$ Z# v4 A, `8 a; r* k1 `4 ]- j Answer The .NET frameworks designers have created a new resource model. Re : X. N2 @* K. ?$ e3 N# M: _; u+ i
sources can be embedded in EXE or DLL files the way Win32 resources are or r : s% p( e* _# cesources files can now be stand-alone files like a single jpg or bmp file. T # v: F/ l0 S7 q& t
here is also the concept of fall-back cultures. If the Swiss German resource & o/ Y* }4 ^ w) E can't be found, the runtime looks for the German resource. If the German re . z5 J$ z* d6 Z3 L% C+ v$ t1 C+ Y4 {source can't be fond, it looks for the "default" resource. Each language wil * f+ Q; R/ o: b7 `
l typically be built and shipped as a separate assembly rather than packagin $ O! I9 I6 \; s4 K. S* U7 b1 ~g everything up into a single file. Like code access security, a full discus 8 O: z/ U$ q+ l) [- f
sion of the new resource model is too much to put here. , {' G Z3 Q3 p% q( t 2 _1 W# z) z" C# g6 K, M* o0 Y/ T) }
' R$ d& H$ W! v& n4 U- d) I
D5 y' ?$ [$ Y( E& T
+ V. @8 ^8 g, ~* V! N wenyy 来自 <a href="http://www.vchelp.net" target="_blank" >http://www.vchelp.net</A> : 1 u) f9 k0 Y+ H' j" }+ f
- j- ~( _. ]& L8 s! p7 t/ u
我想应该这样说,一种新语言的出现会在一定的功能领域上替代其他的开发语言,以 6 r% H4 g6 _" ~ c4 r
前的开发语言的使用范围会缩小,但不会消失。(就算是出于保护现有资源的目的) ' C/ l( F. T. n0 `9 M7 @
9 H/ i8 G7 r8 ?4 G ~9 x3 i7 M8 z 但没有一中语言是十全十美的, 7 t3 p9 b4 n: D$ C' f- p# c
4 Q+ Y5 b4 f: b0 U3 y, I
JAVA,C#都不是。 9 O3 |& T% H8 ?; m& T+ s
2 v) `6 a9 e0 ]# V! T# W$ {+ c
, P1 e% n- O2 G , ^1 t) W1 x1 g; w o( D1 Z$ W wenyy 来自 <a href="http://www.vchelp.net" target="_blank" >http://www.vchelp.net</A> : / f2 u- m% S. N4 n2 Z7 h( m+ R
" d6 g0 {& t& B8 | 》》恶魔吹着笛子来 * @5 }; l( }& p& W3 j* B6 P + X' I' p: y+ H! P* k 你好, $ F9 N: E( |( O7 H% `; A% E # O0 }! `! r0 p) V6 K
很高兴能够与你进行讨论, 9 C+ E. Y, V; z: R1 z
' ~$ P) k; t/ o3 F, U3 B8 O
虽然本站名字叫做vchelp.net 2 M2 n0 j& ?& T; X- u / I* O, [0 j$ I# t1 Y
但我不排斥其他的开发语言,只是自己的能力有限不能将本站内容扩展到其他的语言 + x" u- e0 G8 T1 t( k. c& p
, " g+ P5 [% e: a # y) I; V( g% N0 e$ B# [ 但我很希望大家在本站对开发中可能遇到的问题和矛盾进行讨论,不论是关于语言还 $ H! W4 T6 {* }+ b1 G是开发方法的。 + L7 i# E0 s, ` V8 D1 e% m
% c h: n# n! R 我想邀请你成为本站个人专栏的作者, 8 e- X2 q; ^6 t/ R3 Y! k3 h - P# u2 B/ y' S. ~; z 你可以发表一些你关于开发的想法,就算是与VC无关也没关系。当然在时间上也没有 % W5 |5 t! F2 E$ v6 `要求,你有时间就写写。 5 Z) ]9 t- N& n# M; t
, T: R1 c- c% \/ x8 g: C% A) X& k w
盼复:<a href="mailtwyy_cq@21cn.com" target="_blank" >wyy_cq@21cn.com</A> 2 n. P: q5 c" m$ N
* {( J7 b- i! O" _. r# q2 m cuixue 来自 http:// : 0 \+ ^: U# m# T
1 D" n4 C \$ H) m& S6 g8 f* E+ Z
看了各位大侠的话,觉得好像在讨论java,其实历来有两派,smth几乎天天在吵, ' ]) `* r; N" j$ f( a; m6 N# @ $ X9 R) W' H9 L& D
喜欢java的同志到各个地方布道,连perl也不放过。呵呵。我个人觉得java先天有一 3 Q: e# w8 W3 r1 T' ]些劣势使得他无法取代c/c++的,他的垃圾收集只不过通过一个线程来完成,这对实时系 $ Y u" M1 x* y+ J统是来不及的,EJB的推出也说明java原来是不适合企业级开发的,没有语言是天生完美 . E+ Q) s& M1 B! o. A( k( K
的。java最大的困难我觉得来自microsoft的刁难,c#的推出无疑会夺走windows平台上 + R7 D: g* E% ~1 f- s2 C$ n的java份额。java的速度也就不说了。jbuidler的速度不能够忍受阿,可是这样一个产 ( Z: K) Z& {$ s$ g) z+ N) p1 @品就是java写的。由于个人见识不够,实在不能理解海量吞吐的 ) U/ e: M" [1 S, j/ j/ X6 Q . q* X* n6 K9 i! k( x server用java.oracle用java是实现了ejb的集成把,他的数据库engine是不是java 的 , C# W9 X, b8 w( i+ f
那?请大侠指点。而且当时号称8i不要操作系统,结果市场反应平平,还好 7 }" o6 v T+ R3 [8 Q6 Y5 r + j' H. p& n! s5 L 搭上了e-commerce这班车,:) ' ~- w7 ~" e9 d! a 0 H' w# E+ ^* Y7 q% _% V( q& H
在说说我对vc和bcb的看法,这两样我都算粗粗用过,紫云影说得挺好的,比较公正。 ! ^% ]; X7 E$ w$ [& |; LMFC的确稳定,ATL未免有点复杂,要不WTL就不会出来了。vcl的源码有一部分是pascal . q; t: l7 Z# ~6 N
写的,这点有点差,不过他的扩展性很好,用用就知道了,决不是好多人认为的vb式的 8 T* W8 ^% Q& M8 P) b
傻瓜工具。道理很简单,应为他是符合ansi标准的c/c++语言。其实vc是不够ansi的,C + y; G, L& B8 T+ A
String就是不符合的,所以bcb用了 AnsiString.可惜bcb不够稳定。 * L8 `- E7 c2 k0 R/ v- a3 Z' c 1 l2 m G8 l, U! T* I4 R3 m
提示太慢。帮助的问题我是这样看得,msdn不是专门给vc的,他是windows开发的指南 + @- ~2 p$ x" {# k; K( x
,用bcb一样也很有用,是个宝贝。 6 n5 _* b( A' D; M j; w+ H0 p, m : n3 N0 P2 m% \ 好了,不说了,反正按需所取把。 : j3 Q8 \3 R: K2 ?) a- } 2 T! t0 ^. n- H* V9 h7 E
cuixue 来自 http:// : , f( S; x3 |& n
1 ^. c5 N8 z% F# j" q5 M/ b* c, X5 Q
xml远程调用无疑是平台无关调用的一大进步,可是这也不能说corba就要消失了, 0 u, K+ M9 a3 X7 D, m0 [4 P! v ( U! Q0 ^% D6 |/ n) k xml这种标记语言虽然提供了强大的标志检索的能力,可是它本身的缺点是与以前系统 ! w, S3 y, {% g4 [2 Y的兼容性,所以最近推出了xhtml以兼容以前的应用。电子商务的应用有不同的类型, 6 X/ L) i' x9 f5 o, ]6 w 8 C. S- c! M" t 对于一般的b2c的应用,sun e1000上跑跑java或许可以,如果是银行的主机,起码 ! x! R7 i5 I8 R7 Z. y 1 z/ ~+ A3 ]4 X) C/ N$ L7 S 1000笔每秒,java是不是可以 那?硬件的提高不是没有限度的,而且现在数据中心和 1 s4 F0 D) W) c4 LOLAP的流行,对实时的要求更高了,实际上对于单位应用硬件资源并没有什么起色。而 ! [. {! G% O1 K1 [2 Q3 d: S$ n
且数据发掘的应用要求对原有资源的兼容,对于中间件而言java开发是有优势的,corb ! s5 ]# c& B' D' o+ k
a提供了对异构网络的良好支持,ejb也在向它靠,毕竟在这个年代,不可能只存在一个 # M( X+ L' I0 t' X6 Z
系统,一种语言,对自身的改造和对异构网络的支持以及原有应用的支持是每种语言都 7 W. t/ B6 H2 @- G8 [- ]6 M要面对的难题。 d4 I8 v, g! @" g% Y
3 h$ `# p* X# h$ X( A1 k9 A4 d, v
5 @' S, a' U3 O " L+ j2 L1 G) B+ C
杨宁 来自 http:// : & i U2 i- a) |" P% W5 S f
/ P- t! t) A2 e4 l1 g: e5 M
世界是多样性的世界。 : G( F3 t4 S8 K ' \* Z+ o: C \! O2 h0 D9 T3 R
不面向应用,一切都是废物。 ( [# ^ G# H. N& R& v
) z W x+ J0 c8 r7 l
学好编译原理和操作系统,以不变应万变。 9 U& U; }+ p" O
} A; s# J/ G- D$ P* b 人的精力有限,面面俱到等于面面难到! i7 T+ a7 b! O2 k& Q
# a: y, f6 F3 a: F% F
妖刀 来自 http:// : . a3 w) A' r3 v$ ^ a3 s% c0 V . s( L- v$ Q; r7 W& [; r 我不会编一辈子程序,我需要简单,快速.我只要他好掌握,能实现功能. ' M" V W+ Y5 \. `% X% r& D `
* k2 e! v2 a, B; o 至于是专家型的C++还是傻瓜型的VB(Delphi也差不多)我不在乎. 0 {; N4 r' r$ ?# c
4 |7 f& [& v3 [+ S( w 老板也不在乎 ' F8 ~6 Z/ K. W1 _* n# g, f. s
& Y8 o$ w* v9 k1 ]' t0 x
TOM 来自 http:// : 1 d& P1 d! D1 E4 [5 k1 G0 R ( g# X" C# U% ]
用VC++和Delphi都各有千秋,Delphi写界面方便,大部分是写数据库程序。但写出来 0 K$ m3 R, a3 ?+ _' z: r的程序太大,如果做一个组件(为HTML写的)还是用VC好,有句话很好,专业的程序员 7 h% m. P. u: c) D ?用VC,聪明的程序员用Delphi, ! O* L8 d$ E" r* Y! w : E1 ?( o: H" ?/ A; m8 [
TOM 来自 http:// : , a) l; q' _! d, x6 H 4 o( n0 o# e1 ^
用VC++和Delphi都各有千秋,Delphi写界面方便,大部分是写数据库程序。但写出来 1 e) ]& l n7 |/ J7 K
的程序太大,如果做一个组件(为HTML写的)还是用VC好,有句话很好,专业的程序员 ) H# r, J: m' X! T* ^4 q9 Z用VC,聪明的程序员用Delphi, 6 j Z$ j: J2 n
- e* t" G) ^" R: I1 ]2 F& c
宇服 来自 http:// : : ?5 B% |9 k3 \% E: R9 N4 a
9 Q6 w0 R1 `1 w7 s1 Z 作为一个真正的程序员,不懂c/c++ 只能与非专业人士一样,改改属性来作程序罢了 8 }, O. C, d& ]# D$ ~& A
。 5 P, j \3 N" s; j: P2 M 0 V; Q; S. y& \+ t 宇服 来自 http:// : 1 s1 |$ \* k+ R 5 C+ \* V( ?: o' x# d5 ]" E 恶魔吹着笛子来的话太可怕了,世界可能只有java存在了????? 5 i$ U% ~- B& e : o2 B9 h0 A! t1 D! \9 _
' i% l3 b. c/ a; I8 D1 r 4 C* M! f$ ] M# C: { wenyy 来自 <a href="http://www.vchelp.net" target="_blank" >http://www.vchelp.net</A> : ! |& |, [0 n( e8 W' U, K
& _( p0 H1 ]- `! {6 _0 G7 m
我很同意杨宁的观点 4 ~. J0 Y! ]1 C
3 r1 ]- C3 M) g+ M 》》》世界是多样性的世界。 不面向应用,一切都是废物。 8 A4 S2 }7 P/ U' o& Q
& s) I3 @8 W0 @' v% B( b5 ^ 3 v# \' C+ P# u! p
; A; s, M E, Y 苏 来自 http:// : / E- O( v3 x2 B' R# Q
. h; B/ m+ T' b3 l* p( e: `2 j
对于DELPHI跟VC的争议已经不是一天两天的了,要理论它们的长短处确实比较困难. ! |' {& O5 h4 X! |/ q' \& ? ; H9 [- @5 C! n5 t# z 作为比较出色的RAD开发工具我认为是DELPHI,VC是称不上RAD的!对于编程者而言,如果 0 S5 P" C$ Y6 I* m! D是低层的东西用VC开发具有明朗的线条--一句一句来,而用DELPHI就必须借用API了(当然 4 s6 N) g6 z1 n3 A6 g2 r
用起来就不是很方便了);而对于从事数据库开发DELPHI不失为一个好工具!我觉得两者各 $ I% k4 n. A5 w- k# @" V6 t- P3 u
有长处吧! 7 M$ {5 j! t O5 L6 _3 U. S# Q ( g: w. [1 l& l& A
雅各宾派 来自 http:// : 4 } R$ \: s) P6 ^, p
3 |$ s- O$ X2 d R- r8 T( ]
呵呵,明朗的线条,此言得之。 1 i3 D3 O6 j u2 u2 d& S- e9 M$ } w + S0 a' F- i6 Q
Hintell 来自 http:// : / E- P8 [0 @* ^1 q/ A3 F } 0 t% }4 Q8 x% u' V) x6 h3 F3 G/ e: {' G+ b 我爱JAVA,如果不是为了谋生,我立马放弃现在的UNIX/C PROGRAMMING,不过幸好搞的算 : h+ i; i2 o Y1 i6 W' G& i是交易中间件 0 C8 Z) ~. H; [9 R9 z" B' n
* }$ J# P* p2 K, i; w+ Y8 z! r6 R
JAVA是个好东东! ! Z$ x! O- y$ w ; k9 Z4 |% x P, _* a" q/ [9 n7 r 恶魔吹着笛子来 来自 : % v* U' L9 B( b7 G! z- T , v9 Y) o5 Q$ u/ i% ~2 h
我从来就没有说果,只有JAVA会存在.我只是说,将来的很多我们熟悉的桌面应用都要以 2 I! B; [# F6 ~+ k+ M5 w9 u7 BWEB服务形式出现(包括我们的现在常用的office,windows,visualstudio等等),而客户端 ! g- n+ ?+ N6 h( p: T; Z仅仅是一个外壳.你没有听说5年以后ms将不再买osftware,而是靠买网上的服务(office ! p6 U2 q: C, a3 z- J
.net,windows.net).这个时候我想传统的c/c++的应用范围就会小的多,而c/c++的升级版 ; S: d1 U) l5 m1 G/ Q2 H
本类似于java,c#就是主流因为他们是为internet设计的而c/c++不是.还有我认为,java * }: l. d6 {. q4 I) ?0 }8 [7 ~9 \- h,c#和c/c++不是对立,要我把java,c#和c/c++对立起来,我宁愿 2 G) }+ m \" l( V7 Q7 ]4 W
: S' U7 b( w0 f- ^7 {
把java,c#看作是c/c++的一种internet延伸和升级,使得c/c++更加符合internet的需 + J" A9 W8 K3 ?) c+ G要.我们用java,c#的时候我们很大程度上使用了c/c++大约60%的legcy功能,我们能不感 ) \0 j1 H4 Y5 C谢c/c++么.我一直强调的是java和c#是C/C++的衍生,我们在用JAVA时我并不感到是在另 4 P: T) I! F6 V& w# m
外一个世界里写程序我感到的是我仍然在C语言的世界.我想我们不该 8 \1 I7 N- t1 u: Z& ^0 R3 m' |) D 7 U3 V! |5 y- _' E
有JAVA,C#和c/c++语言的门户之间.有可能的话我希望称他们为c语言族(c/c++/java| 3 E, s3 @& D& dc#). 2 I, @, z$ D3 c # | y* U# q- f8 s2 b9 }8 N8 Y% e6 {
hfgh 来自 http://无 : + l+ l- K& S4 \1 v/ m4 F 8 u. o. T1 T2 j! o$ a: U3 C; @1 ]
不要再去争论什么DELPHI、VC了,语言只是工具。软件的关键是创新和设计, % U' Y4 {+ e6 U0 `6 A
8 H' E. [6 G$ S1 V. C2 `$ B1 L0 U/ V
有了这个前提,用什么工具去做就看你熟悉什么工具了,看你的工具能不能 0 u# E9 H6 s& s