Kinh doanh - Marketing
Kinh tế quản lý
Biểu mẫu - Văn bản
Tài chính - Ngân hàng
Công nghệ thông tin
Tiếng anh ngoại ngữ
Kĩ thuật công nghệ
Khoa học tự nhiên
Khoa học xã hội
Văn hóa nghệ thuật
Sức khỏe - Y tế
Văn bản luật
Nông Lâm Ngư
Kỹ năng mềm
Luận văn - Báo cáo
Giải trí - Thư giãn
Tài liệu phổ thông
Văn mẫu
Giới thiệu
Đăng ký
Đăng nhập
Tìm
Danh mục
Kinh doanh - Marketing
Kinh tế quản lý
Biểu mẫu - Văn bản
Tài chính - Ngân hàng
Công nghệ thông tin
Tiếng anh ngoại ngữ
Kĩ thuật công nghệ
Khoa học tự nhiên
Khoa học xã hội
Văn hóa nghệ thuật
Y tế sức khỏe
Văn bản luật
Nông lâm ngư
Kĩ năng mềm
Luận văn - Báo cáo
Giải trí - Thư giãn
Tài liệu phổ thông
Văn mẫu
Thông tin
Điều khoản sử dụng
Quy định bảo mật
Quy chế hoạt động
Chính sách bản quyền
Giới thiệu
Đăng ký
Đăng nhập
0
Trang chủ
Công Nghệ Thông Tin
Kỹ thuật lập trình
A Guide to MATLAB Object-Oriented Programming phần 9
Đang chuẩn bị liên kết để tải về tài liệu:
A Guide to MATLAB Object-Oriented Programming phần 9
Diễm Liên
98
38
pdf
Đang chuẩn bị nút TẢI XUỐNG, xin hãy chờ
Tải xuống
Theo quy ước, khi nó tồn tại, điều này thường nên được đối số đầu tiên trong danh sách đối số. Với các biến số trong danh sách đối số đầu vào, đầu ra tên biến được thêm vào từ điển dữ liệu. Bình luận: giữ một văn bản mô tả chức năng. Mô tả văn bản sẽ được thêm vào các ý kiến tiêu đề khi chức năng được tạo ra. | 19 Composition and a Simple Container Class As a further demonstration of composition we make an initial foray into designing and implementing a general container class. A general container is different from an array because it can hold different types. A general container is different from a cell array because all objects must descend from the same parent. For example a general cShape container can hold both cStar and cDiamond objects because they both use cShape as a parent. A container is also different from a cell array because a container has a structure-like interface. The interface makes a container behave a lot like an object array. Rather than looping over each element in the container clients can use vector syntax. Often the loop still exists however it is now hidden behind the container s interface. Developing a set of standard containers compatible with the general computer-engineering literature or with National Institute of Standards NIST definitions would be an enormous undertaking. The goals for this chapter s container are much less ambitious. The primary goal is to demonstrate one potential use of composition. A secondary goal is to produce a container that might be useful as is or at least produce a container that can be easily improved. The container developed for this chapter isn t perfect but with what you already know you can fix all of its deficiencies. 19.1 BUILDING CONTAINERS To implement a container several details are important. First we need to specify the object type held by the container. Any object that passes an isa test for the specified type will be allowed in. Thus objects of the specified type and objects using the specified type as a parent are okay to add to the container. For the example we will specify cShape as the object type. That will allow the container to hold cShape cStar and cDiamond objects. If we want to create new shape classes the container will hold them too. Of course these new classes must have cShape .
TÀI LIỆU LIÊN QUAN
Ebook A guide to MATLAB for beginners and experienced users: Part 1
A Guide to MATLAB® for Beginners and Experienced Users: Part 1
A Guide to MATLAB® for Beginners and Experienced Users: Part 2
A Guide to MATLAB® for Beginners and Experienced Users
Bài giảng Matlab ứng dụng thiết kế điều khiển – ThS Nguyễn Tấn Phúc
Ebook Applied numerical methods with MATLAB for engineers and scientists (3rd edition): Part 2
Hướng dẫn Matlab Guide
Ứng dụng Fuzzy_Inference, Guide trong Matlab để xây dựng phần mềm tính sai số và gia công kết quả đo lường
Đề tài: ỨNG DỤNG GUI TRONG MATLAB VÀ SIMULINK TRONG BÀI TOÁN CỤ THỂ
Đồ án tốt nghiệp: Ứng dụng phần mềm GUIDE trong Matlab để thiết kế động cơ không đồng bộ Rotor lồng sóc
crossorigin="anonymous">
Đã 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.