Properties in the Real World

 <  Day Day Up  >  

A key goal of object-oriented programming (OOP) is to design the objects for the system to closely mirror the characteristics and behaviors of the real-world objects they represent. The Loan example shows this well; loans have three properties inherent to them: the amount being borrowed (principal), the interest (rate), and the time that will be taken to repay the loan ( term ). These are properties of a loan, and they describe a loan pretty thoroughly. Everywhere we look in the real world, the objects we interact with have properties. Even the book you are reading now has properties, as shown in Table 3.1.

Table 3.1. Properties of This Book




Tapper, Talbot, Haffner


New Riders



Hopefully, this illustrates that properties aren't really that foreign of a concept; everything has properties, even you!

 <  Day Day Up  >  

Object-Oriented Programming with ActionScript 2.0
Object-Oriented Programming with ActionScript 2.0
ISBN: 0735713804
EAN: 2147483647
Year: 2004
Pages: 162 © 2008-2017.
If you may any questions please contact us: