10.12.2012 Views

ActionScript 3.0 Design Patterns.pdf - VideoTutorials-bg.com

ActionScript 3.0 Design Patterns.pdf - VideoTutorials-bg.com

ActionScript 3.0 Design Patterns.pdf - VideoTutorials-bg.com

SHOW MORE
SHOW LESS

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

understanding of OOP’s many nuances. We ourselves were surprised at how different<br />

design patterns brought out different perspectives on the same OOP concept and<br />

helped further clarify it.<br />

To get started, we’ll review the four basic OOP concepts:<br />

• Abstraction<br />

• Encapsulation<br />

• Inheritance<br />

• Polymorphism<br />

Each of these concepts needs reflection, and if you’re new to OOP, don’t worry<br />

about getting it right the first time. We go over these concepts time and again in the<br />

design pattern chapters.<br />

Abstraction<br />

In general, an abstraction is a model or ideal. You don’t have all of the details, but<br />

you have the general parameters that can be filled in with details. Further, an<br />

abstraction is clear enough for you to tell one abstraction from another. Take, for<br />

example, two jobs your <strong>com</strong>pany is trying to fill. One’s for a Web designer and the<br />

other’s for a programmer. To advertise for the position, you would not describe the<br />

person as a specific person but instead in terms of the characteristics you want for<br />

the position. You might have the two abstractions representing the two different<br />

positions:<br />

Two Positions Open:<br />

• Programmer<br />

— Experienced with multi-programmer projects<br />

— Experienced with middleware and database programming<br />

— ECMAScript programming background<br />

— OOP and <strong>Design</strong> Pattern programming skills<br />

• Web designer<br />

— Experienced with creating Web graphics<br />

— Familiar with animation graphics<br />

— Can work with vector graphics<br />

— Client-centered approach<br />

You can tell the difference between the two positions and their general requirements<br />

(properties), but the details are left fairly open. A programmer is unlikely to apply for<br />

the Web designer position and a designer is just as unlikely to apply for the<br />

programmer position. However, a pool of applicants could have a wide range of<br />

Abstraction | 11

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!