More Effective C++(中文版):35个改善编程与设计的有效方法

More Effective C++(中文版):35个改善编程与设计的有效方法
分享
扫描下方二维码分享到微信
打开微信,点击右上角”+“,
使用”扫一扫“即可将网页分享到朋友圈。
作者: [美] ,
2011-01
版次: 1
ISBN: 9787121125706
定价: 59.00
装帧: 平装
开本: 16开
纸张: 胶版纸
页数: 317页
字数: 500千字
正文语种: 简体中文
原版书名: More Effective C++:35 New Ways to Improve Your Programs and Designs
  •   继EffectiveC++之后,ScottMeyers于1996推出这本“续集”。条款变得比较少,页数倒是多了一些,原因是这次选材比“第一集”更高阶,尤其是第5章。Meyers将此章命名为技术(techniques),并明白告诉你,其中都是一些patterns,例如virtualconstructors,smartpointers,referencecounting,proxyclasses,doubledispatching……这一章的每个条款篇幅都达15~30页之多,实在让人有“山重水复疑无路,柳暗花明又一村”之叹。
      虽然出版年代稍嫌久远,但本书并没有第2版,原因是当其出版之时(1996),C++Standard已经几乎定案,《MoreEffectiveC++:35个改善编程与设计的有效方法(中文版)》即依当时的标准草案而写,其与现今的C++标准规范几乎相同。而且可能变化的几个弹性之处,Meyers也都有所说明与提示。读者可以登录作者提供的网址,看看上下两集的勘误与讨论(数量之多,令人惊恐。幸好多是技术讨论或文字斟酌,并没有什么重大误失)。
      读者对象:程序设计学习者和在职开发人员。   ScottMeyers,世界的C++软件开发技术专业之一。他是两本畅销书EffectiveC++和MoreEffectiveC++的作者,以前曾经是C++Report的专栏作家。他经常为C/C++UsersJournal和Dr.Dobb'sJournal撰稿,也为全球范围内的客户做咨询活动。他也是AdvisoryBoardsforNumeriXLLC和InfoCruiser公司的成员。他拥有BrownUniversity的计算机科学博士学位。
      侯捷,集计算机技术读物之著、泽、评于一身,足《多态与虚拟》和《STL源码剖析》的作者,《Run!Pc》杂志、《程序员》杂志的知名专栏作家,也是极其号召力的大学教师与研讨会讲师。他于1989年获得中国台湾清华大学动机系硕士学位。 导读(Introduction)
    基础议题(Basics)
    条款1:仔细区别pointers和references
    Distinguishbetweenpointersandreferences.
    条款2:最好使用C++转型操作符
    PreferC++-stylecasts.
    条款3:绝对不要以多态(polymorphically)方式处理数组
    Nevertreatarrayspolymorphically.
    条款4:非必要不提供defaultconstructor
    Avoidgratuitousdefaultconstructors.
    操作符(Operators)
    条款5:对定制的"类型转换函数"保持警觉
    Bewaryofuser-definedconversionfunctions.
    条款6:区别increment/decrement操作符的前置(prefix)和后置(postfix)形式
    Distinguishbetweenprefixandpostfixformsofincrementanddecrementoperators.
    条款7:千万不要重载&&,||和,操作符
    Neveroverload&&,||,or,.
    条款8:了解各种不同意义的new和delete
    Understandthedifferentmeaningsofnewanddelete

    异常(Exceptions)
    条款9:利用destructors避免泄漏资源
    Usedestructorstopreventresourceleaks.
    条款10:在constructors内阻止资源泄漏(resourceleak)
    Preventresourceleaksinconstructors.
    条款11:禁止异常(exceptions)流出destructors之外
    Preventexceptionsfromleavingdestructors.
    条款12:了解"抛出一个exception"与"传递一个参数"或"调用一个虚函数"之间的差异
    Understandhowthrowinganexceptiondiffersfrompassingaparameterorcallingavirtualfunction.
    条款13:以byreference方式捕捉exceptions
    Catchexceptionsbyreference.
    条款14:明智运用exceptionspecifications
    Useexceptionspecificationsjudiciously.
    条款15:了解异常处理(exceptionhandling)的成本
    Understandthecostsofexceptionhandling.

    效率(Efficiency)
    条款16:谨记80-20法则
    Rememberthe80-20rule.
    条款17:考虑使用lazyevaluation(缓式评估)
    Considerusinglazyevaluation.
    条款18:分期摊还预期的计算成本
    Amortizethecostofexpectedcomputations.
    条款19:了解临时对象的来源
    Understandtheoriginoftemporaryobjects.
    条款20:协助完成"返回值优化(RVO)"
    Facilitatethereturnvalueoptimization.
    条款21:利用重载技术(overload)避免隐式类型转换(implicttypeconversions)
    Overloadtoavoidimplicittypeconversions.
    条款22:考虑以操作符复合形式(op=)取代其独身形式(op)
    Considerusingop=insteadofstand-aloneop.
    条款23:考虑使用其他程序库
    Consider alternativelibraries.
    条款24:了解virtualfunctions、multipleinheritance、virtualbaseclasses、runtimetypeidentification的成本
    Understandthecostsofvirtualfunctions,multipleinheritance,virtualbaseclasses,andRTTI.

    技术(Techniques,Idioms,Patterns)
    条款25:将constructor和non-memberfunctions虚化
    Virtualizingconstructorsandnon-memberfunctions.
    条款26:限制某个class所能产生的对象数量
    Limitingthenumberofobjectsofaclass.
    条款27:要求(或禁止)对象产生于heap之中
    Requiringorprohibitingheap-basedobjects.
    条款28:SmartPointers(智能指针)
    条款29:Referencecounting(引用计数)
    条款30:Proxyclasses(替身类、代理类)
    条款31:让函数根据一个以上的对象类型来决定如何虚化
    Makingfunctionsvirtualwithrespecttomorethanoneobject.

    杂项讨论(Miscellany)
    条款32:在未来时态下发展程序
    Programinthefuturetense.
    条款33:将非尾端类(non-leafclasses)设计为抽象类(abstractclasses)
    Makenon-leafclassesabstract.
    条款34:如何在同一个程序中结合C++和C
    UnderstandhowtocombineC++andCinthesameprogram.
    条款35:让自己习惯于标准C++语言
    Familiarizeyourselfwiththelanguagestandard.
    推荐读物
    auto_ptr实现代码
    索引(一)(GeneralIndex)
    索引(二)(IndexofExampleClasses,Functions,andTempltes)
  • 内容简介:
      继EffectiveC++之后,ScottMeyers于1996推出这本“续集”。条款变得比较少,页数倒是多了一些,原因是这次选材比“第一集”更高阶,尤其是第5章。Meyers将此章命名为技术(techniques),并明白告诉你,其中都是一些patterns,例如virtualconstructors,smartpointers,referencecounting,proxyclasses,doubledispatching……这一章的每个条款篇幅都达15~30页之多,实在让人有“山重水复疑无路,柳暗花明又一村”之叹。
      虽然出版年代稍嫌久远,但本书并没有第2版,原因是当其出版之时(1996),C++Standard已经几乎定案,《MoreEffectiveC++:35个改善编程与设计的有效方法(中文版)》即依当时的标准草案而写,其与现今的C++标准规范几乎相同。而且可能变化的几个弹性之处,Meyers也都有所说明与提示。读者可以登录作者提供的网址,看看上下两集的勘误与讨论(数量之多,令人惊恐。幸好多是技术讨论或文字斟酌,并没有什么重大误失)。
      读者对象:程序设计学习者和在职开发人员。
  • 作者简介:
      ScottMeyers,世界的C++软件开发技术专业之一。他是两本畅销书EffectiveC++和MoreEffectiveC++的作者,以前曾经是C++Report的专栏作家。他经常为C/C++UsersJournal和Dr.Dobb'sJournal撰稿,也为全球范围内的客户做咨询活动。他也是AdvisoryBoardsforNumeriXLLC和InfoCruiser公司的成员。他拥有BrownUniversity的计算机科学博士学位。
      侯捷,集计算机技术读物之著、泽、评于一身,足《多态与虚拟》和《STL源码剖析》的作者,《Run!Pc》杂志、《程序员》杂志的知名专栏作家,也是极其号召力的大学教师与研讨会讲师。他于1989年获得中国台湾清华大学动机系硕士学位。
  • 目录:
    导读(Introduction)
    基础议题(Basics)
    条款1:仔细区别pointers和references
    Distinguishbetweenpointersandreferences.
    条款2:最好使用C++转型操作符
    PreferC++-stylecasts.
    条款3:绝对不要以多态(polymorphically)方式处理数组
    Nevertreatarrayspolymorphically.
    条款4:非必要不提供defaultconstructor
    Avoidgratuitousdefaultconstructors.
    操作符(Operators)
    条款5:对定制的"类型转换函数"保持警觉
    Bewaryofuser-definedconversionfunctions.
    条款6:区别increment/decrement操作符的前置(prefix)和后置(postfix)形式
    Distinguishbetweenprefixandpostfixformsofincrementanddecrementoperators.
    条款7:千万不要重载&&,||和,操作符
    Neveroverload&&,||,or,.
    条款8:了解各种不同意义的new和delete
    Understandthedifferentmeaningsofnewanddelete

    异常(Exceptions)
    条款9:利用destructors避免泄漏资源
    Usedestructorstopreventresourceleaks.
    条款10:在constructors内阻止资源泄漏(resourceleak)
    Preventresourceleaksinconstructors.
    条款11:禁止异常(exceptions)流出destructors之外
    Preventexceptionsfromleavingdestructors.
    条款12:了解"抛出一个exception"与"传递一个参数"或"调用一个虚函数"之间的差异
    Understandhowthrowinganexceptiondiffersfrompassingaparameterorcallingavirtualfunction.
    条款13:以byreference方式捕捉exceptions
    Catchexceptionsbyreference.
    条款14:明智运用exceptionspecifications
    Useexceptionspecificationsjudiciously.
    条款15:了解异常处理(exceptionhandling)的成本
    Understandthecostsofexceptionhandling.

    效率(Efficiency)
    条款16:谨记80-20法则
    Rememberthe80-20rule.
    条款17:考虑使用lazyevaluation(缓式评估)
    Considerusinglazyevaluation.
    条款18:分期摊还预期的计算成本
    Amortizethecostofexpectedcomputations.
    条款19:了解临时对象的来源
    Understandtheoriginoftemporaryobjects.
    条款20:协助完成"返回值优化(RVO)"
    Facilitatethereturnvalueoptimization.
    条款21:利用重载技术(overload)避免隐式类型转换(implicttypeconversions)
    Overloadtoavoidimplicittypeconversions.
    条款22:考虑以操作符复合形式(op=)取代其独身形式(op)
    Considerusingop=insteadofstand-aloneop.
    条款23:考虑使用其他程序库
    Consider alternativelibraries.
    条款24:了解virtualfunctions、multipleinheritance、virtualbaseclasses、runtimetypeidentification的成本
    Understandthecostsofvirtualfunctions,multipleinheritance,virtualbaseclasses,andRTTI.

    技术(Techniques,Idioms,Patterns)
    条款25:将constructor和non-memberfunctions虚化
    Virtualizingconstructorsandnon-memberfunctions.
    条款26:限制某个class所能产生的对象数量
    Limitingthenumberofobjectsofaclass.
    条款27:要求(或禁止)对象产生于heap之中
    Requiringorprohibitingheap-basedobjects.
    条款28:SmartPointers(智能指针)
    条款29:Referencecounting(引用计数)
    条款30:Proxyclasses(替身类、代理类)
    条款31:让函数根据一个以上的对象类型来决定如何虚化
    Makingfunctionsvirtualwithrespecttomorethanoneobject.

    杂项讨论(Miscellany)
    条款32:在未来时态下发展程序
    Programinthefuturetense.
    条款33:将非尾端类(non-leafclasses)设计为抽象类(abstractclasses)
    Makenon-leafclassesabstract.
    条款34:如何在同一个程序中结合C++和C
    UnderstandhowtocombineC++andCinthesameprogram.
    条款35:让自己习惯于标准C++语言
    Familiarizeyourselfwiththelanguagestandard.
    推荐读物
    auto_ptr实现代码
    索引(一)(GeneralIndex)
    索引(二)(IndexofExampleClasses,Functions,andTempltes)
查看详情
您可能感兴趣 / 更多
More Effective C++(中文版):35个改善编程与设计的有效方法
Moldflow模流分析基础教程
李丽华
More Effective C++(中文版):35个改善编程与设计的有效方法
Mourning Sickness: Hegel and the French Revolution
Comay;Rebecca
More Effective C++(中文版):35个改善编程与设计的有效方法
Modern Engineering for Design of Liquid Propellant Rocket Engines
Huzel;Dieter K.;Huang;David H.;D. Huzel and D. Huang;Rocketdyne Divisi
More Effective C++(中文版):35个改善编程与设计的有效方法
Moominvalley in November
Jansson;Tove;Jansson;Tove;Hart;Kingsley
More Effective C++(中文版):35个改善编程与设计的有效方法
Montessori: Shape Work
George;Bobby;George;June;Nassner;Alyssa
More Effective C++(中文版):35个改善编程与设计的有效方法
Modbus总线技术与应用系统
方虎生
More Effective C++(中文版):35个改善编程与设计的有效方法
Mosby内分泌生殖与生理学(原书第5版)
[美]Bruce·A.怀特;约翰·R.哈利森;丽莎·M.梅尔曼
More Effective C++(中文版):35个改善编程与设计的有效方法
Moonshot: The Flight of Apollo 11
Floca;Brian
More Effective C++(中文版):35个改善编程与设计的有效方法
Modern Engineering Graphics(Exercise Workbook Included)现代工程图学(含习题集)Modern Engineering Graphics Exe
王静秋;卢敏;贾皓丽
More Effective C++(中文版):35个改善编程与设计的有效方法
Modern Communications Receiver Design and Technology
Drentea;Cornell
More Effective C++(中文版):35个改善编程与设计的有效方法
Modeling and Inverse Problems in Imaging Analysis
Foster;Kari A.;Chalmond;Bernard
More Effective C++(中文版):35个改善编程与设计的有效方法
Money Talks: How to Make a Million as a Speaker
Weiss;Alan
系列丛书 / 更多
More Effective C++(中文版):35个改善编程与设计的有效方法
Moldflow模流分析基础教程
李丽华
More Effective C++(中文版):35个改善编程与设计的有效方法
Mourning Sickness: Hegel and the French Revolution
Comay;Rebecca
More Effective C++(中文版):35个改善编程与设计的有效方法
Modern Engineering for Design of Liquid Propellant Rocket Engines
Huzel;Dieter K.;Huang;David H.;D. Huzel and D. Huang;Rocketdyne Divisi
More Effective C++(中文版):35个改善编程与设计的有效方法
Moominvalley in November
Jansson;Tove;Jansson;Tove;Hart;Kingsley
More Effective C++(中文版):35个改善编程与设计的有效方法
Montessori: Shape Work
George;Bobby;George;June;Nassner;Alyssa
More Effective C++(中文版):35个改善编程与设计的有效方法
Modbus总线技术与应用系统
方虎生
More Effective C++(中文版):35个改善编程与设计的有效方法
Mosby内分泌生殖与生理学(原书第5版)
[美]Bruce·A.怀特;约翰·R.哈利森;丽莎·M.梅尔曼
More Effective C++(中文版):35个改善编程与设计的有效方法
Moonshot: The Flight of Apollo 11
Floca;Brian
More Effective C++(中文版):35个改善编程与设计的有效方法
Modern Engineering Graphics(Exercise Workbook Included)现代工程图学(含习题集)Modern Engineering Graphics Exe
王静秋;卢敏;贾皓丽
More Effective C++(中文版):35个改善编程与设计的有效方法
Modern Communications Receiver Design and Technology
Drentea;Cornell
More Effective C++(中文版):35个改善编程与设计的有效方法
Modeling and Inverse Problems in Imaging Analysis
Foster;Kari A.;Chalmond;Bernard
More Effective C++(中文版):35个改善编程与设计的有效方法
Money Talks: How to Make a Million as a Speaker
Weiss;Alan
相关图书 / 更多
More Effective C++(中文版):35个改善编程与设计的有效方法
Moldflow模流分析基础教程
李丽华
More Effective C++(中文版):35个改善编程与设计的有效方法
Mourning Sickness: Hegel and the French Revolution
Comay;Rebecca
More Effective C++(中文版):35个改善编程与设计的有效方法
Modern Engineering for Design of Liquid Propellant Rocket Engines
Huzel;Dieter K.;Huang;David H.;D. Huzel and D. Huang;Rocketdyne Divisi
More Effective C++(中文版):35个改善编程与设计的有效方法
Moominvalley in November
Jansson;Tove;Jansson;Tove;Hart;Kingsley
More Effective C++(中文版):35个改善编程与设计的有效方法
Montessori: Shape Work
George;Bobby;George;June;Nassner;Alyssa
More Effective C++(中文版):35个改善编程与设计的有效方法
Modbus总线技术与应用系统
方虎生
More Effective C++(中文版):35个改善编程与设计的有效方法
Mosby内分泌生殖与生理学(原书第5版)
[美]Bruce·A.怀特;约翰·R.哈利森;丽莎·M.梅尔曼
More Effective C++(中文版):35个改善编程与设计的有效方法
Moonshot: The Flight of Apollo 11
Floca;Brian
More Effective C++(中文版):35个改善编程与设计的有效方法
Modern Engineering Graphics(Exercise Workbook Included)现代工程图学(含习题集)Modern Engineering Graphics Exe
王静秋;卢敏;贾皓丽
More Effective C++(中文版):35个改善编程与设计的有效方法
Modern Communications Receiver Design and Technology
Drentea;Cornell
More Effective C++(中文版):35个改善编程与设计的有效方法
Modeling and Inverse Problems in Imaging Analysis
Foster;Kari A.;Chalmond;Bernard
More Effective C++(中文版):35个改善编程与设计的有效方法
Money Talks: How to Make a Million as a Speaker
Weiss;Alan