Lesson 11. Advanced Object-Oriented Design
Basic object-oriented design requires that you learn the basic syntax of a class. You learned how to write a class in Lesson 6, "Custom Classes." However, learning just the basic syntax is just ...
What You Will Learn
In this lesson you will:
Learn how to correct scope issues that occur in classesWrite classes that use encapsulationWork with compositionDispatch events
...
Correcting Scope Errors with Delegate
There are many classes in ActionScript that use the callback event handler method style. For example, MovieClip uses callback methods such as onPress() and onRelease() to handle mouse events, and LoadVars uses...
Understanding Encapsulation
A basic principle of object-oriented design is encapsulation, which means that a class hides the internals while providing a robust and flexible public API (meaning properties and methods) by which it can interact. The ...
Applying Composition
The relationship that classes have can be generally grouped into "is a" and "has a" categories. When a class has an "is a" relationship with another class, we call that inheritance. (Inheritance i...
Using Composition and Inheritance Together
Inheritance and composition aren't in opposition; they can work together. In this next task, you'll build a more generic superclass, MovieClipContainer, which wraps much of the MovieClip class API. Then, ...
Dispatching Events
There are lots of ways to design an application. Each has relative advantages and disadvantages. Yet there are general principles that can help to make designs more flexible and manageable. One such principle states that loosely...
What You Have Learned
In this lesson you have:
Learned that when you work with event handlers of class properties you frequently run into issues of incorrect scope (pages 269270)Discovered that you can correct scope issues with the Delegate.creat...
AJAX popular information C# language guides Windows books and cookbooks
.......
С 2009 года мы стали переводить структура сайта на различные языки. Сайт теперь будет содержать книги не только на английском языке, но также и на других европейских языках, в том числе и на Русском языке.