View Single Post
Old 08-02-2006, 12:43   #4 (permalink)
Luke Redpath
Barney army!
 
Luke Redpath's Avatar
 
Join Date: Mar 2003
Location: London
Posts: 692
It's well worth getting a good grounding in OOP in general and most books that cover OOP will likely be Java or C# based. Having had a brief look at some ActionScript code, Java shouldn't be too cryptic to you so look here:

http://java.sun.com/docs/books/tutorial/java/concepts/

A few tips and things to remember:

* one of the core principles of OOP is encapsulation. A good article that highlights this is here - ask, don't tell
* favour composition over inheritance - see here
* keep classes small and specific - they should only be focussed on one task. Avoid huge, god classes that try to do everything. Try and keep your code loosely coupled

Once you start to get to grips with the basics, take a look into design patterns. Obviously, don't run before you can walk, but OOP design patterns can be very useful (but don't get obssesed with them...i.e., don't sit around asking "which pattern should I use for this?" - they tend to reveal themselves).

Finally, look into unit testing and even better, test-driven development. A quick google reveals that an ActionScript unit testing framework called AS2Unit. Info on test first/driven development.
__________________
Luke Redpath .::. Software Engineer .::. Reevoo - Real Reviews From Real Customers
  Reply With Quote