Instance Property


A Boolean value that determines the off/on state of the switch.


var isOn: Bool { get set }


This property allows you to retrieve and set (without animation) a value determining whether the UISwitch object is on or off.

See Also

Setting the Off/On State

func setOn(Bool, animated: Bool)

Set the state of the switch to On or Off, optionally animating the transition.