The inventor mentor-Appendix A: getting started with object-oriented programming for C programmers

Source: Internet
Author: User

Appendix A: Introduction to object-oriented programming for C programmers

 

Open Inventor is an object-oriented toolkit for developing 3D programs. Although it is developed in C ++, it also contains C programming interfaces. This book mentions many concepts such as classes, subclasses, and other object-oriented programming. All examples in this book are written in C ++. If, before reading this book, the reader has a certain understanding of "classes" and object-oriented programming methods, you will be able to learn as much as possible from this book (you will get the most from this book if you have a reasonable understanding of classes and objected-oriented programming before you begin reading it).

 

This appendix introduces C programmers to some introduction to object-oriented programming and some introduction to the C language interface concepts to be discussed later. If you are familiar with the object-oriented programming method, skip section 1 of this appendix and ignore the example code in the appendix. For details about the C Programming Interface of inventor, see Appendix B.

 

This chapter includes the following sections:

L "what is an object-oriented programming method ?" Two basic concepts of object-oriented programming are introduced: data abstraction and inheritance derivation.

L "Example of a class: ball", through the development of a real C ++ class example, illustrates the concept of object-oriented programming.

L "reading suggestion": We suggest you read more about C ++.

 

 

What is an object-oriented programming method?

Many successful programmers are using this technology before they know the object-oriented technology. We may have heard that programmers describe an execution function as"Module". Modular code has a clearly defined interface, which can still be used normally without the need to know how it is written. Modular code can be reused by many programs, reducing the programmer's learning time. It allows the code inside the module to be modified without affecting other programs using it. It can prevent programmers from being entangled in program details. Programming interfaces only define functions and do not care about specific implementations.

 

 

For the complete translation of this chapter, please download the following link:

The inventor mentorOriginal English version. Download

The inventor mentorChinese translation. Download

The inventor mentorSample Code. Download

 

 

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.