Just a check of my reading so far.
I couldn't find these simple explanations anywhere. 'seemed the docs wanted to explain to death the concept of OOP but never actually gets around to actually explaining the syntax which causes the OOP behavior.
Does:
1)
- (void) method: argument
{
}
cause the method method to be defined and called when ever the event connected to the method occurs or when this method is called by another method, but only from with in its parent?
2)
+ ( void) method: argument
{
}
cause same but can be called from outside its parent class?
3)
[self rotateArmToDegree:kDisplacemntAngle];
cause the value of the constant kDisplacementAngle to be passed as an arguement to the method rotateArmToDegree, while self simply identifies the method rotateArmToDegree as a method of the class defined in this implementation file .m ?
4)
[metronomeArm.layer removeAllAnimations];
Cause the method removeAllAnimations to be sent to the method layer of the class metronomeArm?
5)
Are methods called messages when they are passed to other methods?
6)
Or are the returned values of methods passed to another method called messages?
7)
Is capitilization entirely option?
8)
Is is optional in some cases only?
9)
#interface MetronomeView : UIView
{
}
cause the list of IBOutlets and other things between the brackets, to be made available as methods of the subclass MetronomeView of the superclass UIView?
Thank you for any help.
Jerry
I couldn't find these simple explanations anywhere. 'seemed the docs wanted to explain to death the concept of OOP but never actually gets around to actually explaining the syntax which causes the OOP behavior.
Does:
1)
- (void) method: argument
{
}
cause the method method to be defined and called when ever the event connected to the method occurs or when this method is called by another method, but only from with in its parent?
2)
+ ( void) method: argument
{
}
cause same but can be called from outside its parent class?
3)
[self rotateArmToDegree:kDisplacemntAngle];
cause the value of the constant kDisplacementAngle to be passed as an arguement to the method rotateArmToDegree, while self simply identifies the method rotateArmToDegree as a method of the class defined in this implementation file .m ?
4)
[metronomeArm.layer removeAllAnimations];
Cause the method removeAllAnimations to be sent to the method layer of the class metronomeArm?
5)
Are methods called messages when they are passed to other methods?
6)
Or are the returned values of methods passed to another method called messages?
7)
Is capitilization entirely option?
8)
Is is optional in some cases only?
9)
#interface MetronomeView : UIView
{
}
cause the list of IBOutlets and other things between the brackets, to be made available as methods of the subclass MetronomeView of the superclass UIView?
Thank you for any help.
Jerry