I'm perusing the UISwitch
documentation, specifically determining whether a switch is on or off.
Most resources suggest using isOn
for this, but the docs give more prominence to on
:
on
A Boolean value that determines the off/on state of the switch.
@property(nonatomic, getter=isOn) BOOL on
What does this definition mean, exactly? It reads as though there is a property 'on' with a renamed getter? What is the purpose of this? Why not just use on
?
And if the setter is isOn
, why can I access on
at all?
I have similar confusion regarding isEditing
and editing
- is the same pattern in play there?