@interface ViewController : UIViewController {
UITextField *a;
}
@property (nonatomic, strong) UITextField *b;
both a and b are iVars, but a does not have implicitly created setter/getter by default.
You can access a by doing something like
if (a.text.length == 0) { ... }
and we call it direct access.
but for b, we use self. to have an access to it.
if (self.b.text.length == 0) { ... }
By using self., you are stating that you want to use setter/getter method to access b.
You can even choose not to use setter/getter by accessing _b (if you have not explicitly synthesized it) directly like below:
if (_b.text.length == 0) { ... }