If you have ever visited the http://ntt.cc, you may paid attention to the serial of Design Patterns in ActionScript. Since http://ntt.cc based on WordPress system and is Blog style but for many readers is more familiar with the book style. We have spent more time in collecting the serial articles and made a PDF file for free download.Download it FREE(or download from here http://ntt.cc/books)
The Table of Contents
Factory Method. 8
Abstract Factory. 10
Template Method. 28
Chain of Responsibility. 55
Final Note. 62
About this series
Last summer, when I was busy finding the internship opportunity, I got a message from my classmate. It said that, someone was looking for a writer to write some articles about Flex/Flash. Though I just had little experience on Flex and Flash, I sent a message to the email address given on the message. Then I got this job, and began to write something about FlexUnit.
Minidxer is a very kind person, when he knew that I’m not familiar with the unit test framework, he gave me a new subject, the 23 design patterns from GoF book. In fact, I just knew few simple patterns, but I wanted to learn all the 23 patterns. So, I prepared to write the articles about this.
During the preparing time, I got an internship offer from Ericsson. As you think, I began my intern life at Ericsson, and used my spare time writing the articles. You know, it’s not easy to write something you’re not familiar with. And I don’t have much time after finish my job. Further more, I began my job hunting in September. All those things result that I only finished five patterns in about four months, from August to November.
After finish my internship and job hunting, I began to write the left patterns. Though I spend many times preparing, there are still many mistakes in the articles. I’m just a fresh man in this field
The main reason I wrote these articles is that I want to learn all the 23 patterns. And it would be my honor that these articles can give you some help.
When you begin to learn a new pattern, carefully look at its intent, every pattern has its corresponding problem field.
Then, try to understand the example, understanding how this pattern affects the current design, what problems it solves. If the example is not so clear, use Google to find more examples about this pattern.
In general, you may find many examples write in C++ or Java; try to transform them into ActionScript. It’s a good way for practice. And with these practice, you’ll know the pattern clearly, not only the implementation, but also its nature.
During you learning of patterns, some books are necessary. You should take the <Design Patterns> by GoF on your desk. And other books, such as <Head First Design Patterns>, are also useful for you, which depend on your level, pick up some books that fit you.
Remember, design is a compromise, when it solves some problems, it brings new problems. So, there is no best pattern, but suitable one.