Summary
So many topics have been touched in this chapter; you now have all the knowledge needed to start
writing some great code. Among other things, so far you have learned:
What classes are and how you can use them in your applications
How to use inheritance to organize your objects and to promote code reuse
How to use typedef to define new types and how to extend them
How to implement your own collections using iterators
How enum s differ from any other languages and how they can be effectively used to lean
your code
In the next chapter, you learn how to organize your classes in files and packages, how to create code
documentation automatically, and how to use Unit Testing in haXe.
??‘
??‘
??‘
??‘
??‘
Organizing Your Code
So far, you have learned a lot about types, classes, OOP, and so on. This chapter will show you
how to manage the code for better organization and efficiency. This means breaking the code in
multiple files that you can reuse from project to project, writing comments that can produce
documentation automatically, and creating a set of tests to check that everything is fine whenever
you make corrections or you introduce new functionalities.
Pages:
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284