Pages

Wednesday, June 17, 2015

Some Questions

Use $this to refer to the current
object. Use self to refer to the
current class. In other words, use
$this->member for non-static members,
use self::$member for static members.

What is Class and Object ?

A class, for example, is like a blueprint for a car.
It defines the shape of the car on paper, with relationships between
the different parts of the car clearly defined and planned out, even
though the car doesn't exist yet .

An object, then, is like the actual Car built
according to that blueprint. The data stored in the object is like the gear, wires, and metal that compose the car: without being
assembled according to the blueprint, it's just a pile of stuff.
However, when it all comes together, it becomes an organized, useful car in running condition .

BUY ME A COFFEE

Follow by Email

Hi! Thank you

Hi! Thank you everyone who reading my article. My major is algorithms & programming. Right now I am working in India. I will like sharing to everyone with my works and if you do interesting with my works, please leave you comment on my blog. Any comments is welcoming.