TAILIEUCHUNG - Chapter 7 - Classes Part II

Proxy class Hide implementation details of another class Knows only public interface of class being hidden Enables clients to use class’s services without giving access to class’s implementation. Used when class definition only uses pointer to another class Prevents need for including header file | Chapter 7: Classes Part II Outline Introduction const (Constant) Objects and const Member Functions Composition: Objects as Members of Classes friend Functions and friend Classes Using the this Pointer Dynamic Memory Management with Operators new and delete static Class Members Data Abstraction and Information Hiding Example: Array Abstract Data Type Example: String Abstract Data Type Example: Queue Abstract Data Type Container Classes and Iterators Proxy Classes Introduction Classes Data abstraction Object-based programming (OBP) Chapters 6-8 Inheritance and polymorphism Chapters 9 and 10 const (Constant) Objects and const Member Functions Principle of least privilege Only allow modification of necessary objects Keyword const Specify object not modifiable Compiler error if attempt to modify const object Example const Time noon( 12, 0, 0 ); Declares const object noon of class Time Initializes to 12 .

TAILIEUCHUNG - Chia sẻ tài liệu không giới hạn
Địa chỉ : 444 Hoang Hoa Tham, Hanoi, Viet Nam
Website : tailieuchung.com
Email : tailieuchung20@gmail.com
Tailieuchung.com là thư viện tài liệu trực tuyến, nơi chia sẽ trao đổi hàng triệu tài liệu như luận văn đồ án, sách, giáo trình, đề thi.
Chúng tôi không chịu trách nhiệm liên quan đến các vấn đề bản quyền nội dung tài liệu được thành viên tự nguyện đăng tải lên, nếu phát hiện thấy tài liệu xấu hoặc tài liệu có bản quyền xin hãy email cho chúng tôi.
Đã phát hiện trình chặn quảng cáo AdBlock
Trang web này phụ thuộc vào doanh thu từ số lần hiển thị quảng cáo để tồn tại. Vui lòng tắt trình chặn quảng cáo của bạn hoặc tạm dừng tính năng chặn quảng cáo cho trang web này.