PHP中文网2017-04-24 09:13:22
myrectgle is an object. myrectgle.origin =xxx sets myrectgle.origin through the dot method. If you use @property when declaring origin, the compiler will automatically generate a - (void)setOrigin:(XYPoint *)pt method; if you write it again in the m file - (void)setOrigin:(XYPoint *)pt is equivalent to repeating After writing this method, setting the origin through the dot method will call this method;