C++ Programming HOWTO - C Programming HOWTO C Programming...

Info icon This preview shows pages 1–5. Sign up to view the full content.

View Full Document Right Arrow Icon
C++ Programming HOW-TO
Image of page 1

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full Document Right Arrow Icon
Table of Contents C++ Programming HOW-TO ........................................................................................................................... 1 Al Dev (Alavoor Vasudevan) [email protected] ............................................................................... 1 1. Introduction .......................................................................................................................................... 1 2. String Class Varieties .......................................................................................................................... 1 3. Best C++ compilers for MS Windows 2000/NT/95/98/ME/XP ......................................................... 1 4. Download String ................................................................................................................................. 1 5. How Can I trust Al Dev's String Class ?? ........................................................................................... 1 6. Usage of String class ............................................................................................................................ 1 7. String.h file .......................................................................................................................................... 1 8. Renaming the String class .................................................................................................................... 2 9. File Class .............................................................................................................................................. 2 10. C++ Zap (Delete) function ................................................................................................................ 2 11. Pointers are problems ........................................................................................................................ 2 12. Usage of my_malloc and my_free .................................................................................................... 2 13. Debug files ......................................................................................................................................... 2 14. Java like API ...................................................................................................................................... 2 15. IDE tools for C++ ............................................................................................................................. 2 16. C++ Online Textbooks and Docs ...................................................................................................... 2 17. C++ Coding Standards ....................................................................................................................... 2 18. C++ Online Docs ............................................................................................................................... 2 19. Memory Tools .................................................................................................................................... 2 20. Related URLs ..................................................................................................................................... 2 21. C++ Scripting Languages .................................................................................................................. 2 22. Templates ........................................................................................................................................... 3 23. STL References ................................................................................................................................. 3 24. Threads in C++ .................................................................................................................................. 3 25. C++ Utilities ...................................................................................................................................... 3 26. Other Formats of this Document ........................................................................................................ 3 27. Translations To Other Languages ...................................................................................................... 3 28. Copyright ........................................................................................................................................... 3 29. Appendix A String Program Files .................................................................................................... 3 1. Introduction .......................................................................................................................................... 3 1.1 C++ v/s Java ....................................................................................................................................... 4 1.2 Which one Ada95, "C", "C++" or Java ?? ......................................................................................... 4 1.3 Problems facing the current C++ compilers ...................................................................................... 5 1.4 COOP - C++ Object Oriented Programming-language ................................................................... 6 2. String Class Varieties ......................................................................................................................... 7 2.1 Multiple Inheritance - Sample Custom String class ........................................................................ 7 3. Best C++ compilers for MS Windows 2000/NT/95/98/ME/XP ........................................................ 8 4. Download String ................................................................................................................................ 9 5. How Can I trust Al Dev's String Class ?? .......................................................................................... 9 6. Usage of String class ............................................................................................................................ 9 6.1 Operators .......................................................................................................................................... 10 6.2 Functions .......................................................................................................................................... 11 7. String.h file ........................................................................................................................................ 11 7.1 StringBuffer.h .................................................................................................................................. 17 7.2 StringTokenizer.h ............................................................................................................................. 18 8. Renaming the String class .................................................................................................................. 19 C++ Programming HOW-TO i
Image of page 2
Table of Contents 8.1 Case 1: Simple rename ..................................................................................................................... 19 8.2 Case 2: Resolve conflict ................................................................................................................... 19 9. File Class ............................................................................................................................................ 20 10. C++ Zap (Delete) function ............................................................................................................. 20 11. Pointers are problems ..................................................................................................................... 21 12. Usage of my_malloc and my_free ................................................................................................. 22 12.1 Garbage Collector for C++ .......................................................................................................... 24 13. Debug files ....................................................................................................................................... 24 14. Java like API .................................................................................................................................... 24 15. IDE tools for C++ .......................................................................................................................... 24 16. C++ Online Textbooks and Docs ................................................................................................... 25 17. C++ Coding Standards ..................................................................................................................... 26 18. C++ Online Docs ............................................................................................................................. 27 18.1 C++ Tutorials ................................................................................................................................. 28 18.2 Useful links .................................................................................................................................... 28 18.3 C++ Quick-Reference ................................................................................................................... 28 18.4 C++ Usenet Newsgroups ............................................................................................................... 28 19. Memory Tools .................................................................................................................................. 29 20. Related URLs ................................................................................................................................... 29 21. C++ Scripting Languages ................................................................................................................ 29 21.1 PIKE (C/C++ Scripting Language) ................................................................................................ 30 21.2 SoftIntegration Ch (C/C++ Scripting Language) ........................................................................... 30 21.3 PHP (C++ Scripting Language) ..................................................................................................... 30 22. Templates ......................................................................................................................................... 30 23. STL References .............................................................................................................................. 31 23.1 Overview of the STL .................................................................................................................... 32 23.2 Header Files ................................................................................................................................... 33 23.3 The Container Classes Interface ................................................................................................... 33 23.4 Vectors .......................................................................................................................................... 34 Constructing Vectors ............................................................................................................... 34 Checking Up on Your Vector .................................................................................................. 35 Accessing Elements of a Vector .............................................................................................. 36 Inserting and Erasing Vector Elements ................................................................................... 37 Vector Iterators ........................................................................................................................ 38 Comparing Vectors .................................................................................................................. 39 23.5 Iterators and the STL ..................................................................................................................... 40 23.6 Lists ................................................................................................................................................ 40 23.7 Sets ................................................................................................................................................ 40 Constructing Sets ...................................................................................................................... 40 What are Function Objects? ...................................................................................................... 42 A Printing Utility ...................................................................................................................... 44 How Many Elements? ............................................................................................................... 45 Checking the Equality of Sets .................................................................................................. 45 Adding and Deleting Elements ................................................................................................. 46 Finding Elements ...................................................................................................................... 47 Set Theoretic Operations .......................................................................................................... 48 23.8 Maps ............................................................................................................................................... 50 23.9 STL Algorithms ............................................................................................................................. 51 C++ Programming HOW-TO ii
Image of page 3

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full Document Right Arrow Icon
Table of Contents 24. Threads in C++ ................................................................................................................................ 51 24.1 Threads Tutorial ............................................................................................................................. 51 24.2 Designing a Thread Class in C++ .................................................................................................. 51 Introduction ............................................................................................................................... 52 Brief Introduction To Threads .................................................................................................. 52 Basic Approach ......................................................................................................................... 52 The Implementation .................................................................................................................. 52 Using The Thread Class ............................................................................................................ 54 Conclusion ................................................................................................................................ 54 25. C++ Utilities .................................................................................................................................... 54 26. Other Formats of this Document ...................................................................................................... 55 26.1 Acrobat PDF format ..................................................................................................................... 56 26.2 Convert Linuxdoc to Docbook format ......................................................................................... 56 26.3 Convert to MS WinHelp format .................................................................................................. 56 26.4 Reading various formats .............................................................................................................. 57 27. Translations To Other Languages .................................................................................................... 57 28. Copyright ......................................................................................................................................... 58 29. Appendix A String Program Files ................................................................................................. 58 C++ Programming HOW-TO iii
Image of page 4
Image of page 5
This is the end of the preview. Sign up to access the rest of the document.

{[ snackBarMessage ]}

What students are saying

  • Left Quote Icon

    As a current student on this bumpy collegiate pathway, I stumbled upon Course Hero, where I can find study resources for nearly all my courses, get online help from tutors 24/7, and even share my old projects, papers, and lecture notes with other students.

    Student Picture

    Kiran Temple University Fox School of Business ‘17, Course Hero Intern

  • Left Quote Icon

    I cannot even describe how much Course Hero helped me this summer. It’s truly become something I can always rely on and help me. In the end, I was not only able to survive summer classes, but I was able to thrive thanks to Course Hero.

    Student Picture

    Dana University of Pennsylvania ‘17, Course Hero Intern

  • Left Quote Icon

    The ability to access any university’s resources through Course Hero proved invaluable in my case. I was behind on Tulane coursework and actually used UCLA’s materials to help me move forward and get everything together on time.

    Student Picture

    Jill Tulane University ‘16, Course Hero Intern