已经有人发过,但是没有什么介绍,我在这里再介绍一下这本书。觉得有参考价值你才有阅读的必要,对吧?
This book makes two assumptions about you, the reader.
The first assumption is that you consider yourself an intermediate or better MATLAB programmer. At every opportunity, example code uses vector syntax. The example code also uses a few important but relatively obscure
MATLAB functions. Example code also uses language features that some might consider to be
advanced topics, for example, function handles and try-catch error handling. Even though code
examples are described line by line, entry-level MATLAB programmers might find the example
code somewhat vexing.
The second assumes only a cursory knowledge of object-oriented programming. I dedicate a
significant amount of the discussion to the introduction of fundamental object-oriented programming
concepts. MATLAB programmers new to object-oriented programming will be able to follow
these discussions and thus gain the ability to implement object-oriented designs. Even so, there is
also plenty of substance to keep seasoned object-oriented programmers on their toes. Going back
to the basics will often reveal important design considerations or expose hidden object-oriented
capability. It is my sincere hope that everyone reading this book will mutter the phrase “I didn’t
know you could do that” at least once.
The organization of this book breaks MATLAB object-oriented programming into three sections.
The first section covers the required elements and focuses on developing a set of functions that
give MATLAB objects first-class status within the environment. In the first section, we will develop
a group of eight indispensable functions. These functions provide object initialization, a simple
intuitive interface, interaction with the environment’s features, and array capability. Even more
important, the group of eight is responsible for an object-oriented concept called encapsulation.
Encapsulation is fundamental to using object-oriented programming as a better, safer alternative
to structures. The default functions in MATLAB seem to be at odds with the information-hiding
principle of encapsulation; but the group of eight brings MATLAB back under control. By the end
of the first section, you will have an excellent working knowledge of MATLAB’s object-oriented
capability and be able to use object-oriented programming techniques to improve software development.
The second section builds on the first by developing strategies and implementations that allow
the construction of hierarchies without compromises. Such hierarchies are important for achieving
true object-oriented programming. The concept of building the next layer of functionality on a firm
foundation of mature code is very compelling and often elusive. Encapsulation certainly helps, but
another object-oriented concept called inheritance makes it much easier to build and traverse an
organizational hierarchy. With inheritance, each successive layer simply builds up additional capability
without changing code in the foundation. As the code matures, bug fixes simply make the
foundation stronger. At first blush, the desire for both first-class status and an inheritance hierarchy
appears incompatible. The section on building a hierarchy delivers a harmonious framework.
The third section discusses advanced strategies and introduces some useful utilities. Advanced
strategies include, among others, type-based function selection, also known as polymorphism;
passing arguments by reference instead of by value; replacing feval’s function handle with an object; and a utility for rapid object-oriented code development. Do not expect to use all the advanced strategies in every software development. Instead, reserve the advanced techniques for difficult situations. Discussing these concepts is important because it opens the door to what are essentially limitless implementation options. It is also nice to know about advanced strategies when the uncommon need arises.
本书我分成4个部分:
part1
part2
part3
part4
[此贴子已经被squarekiss于2008-9-28 9:12:32编辑过]