Since I've started on iPhone development I've been kinda confused as to which is the best way to access data as a member in a Class.
Let's say I have a class called MyClass, and in it I have:
@interface MyClass : NSObject {
int myInt;
}
@property (nonatomic, assign) int myInt;
In the implementation, is it better to do this:
myObject.myInt = 1;
Or this?
[myObject setMyInt:1];
This goes for reading the value too.
int newInt = myObject.myInt;
vs.
int newInt = [myObject myInt];
Thanks for your help!