Switch
@available(iOS 9.0, *)
public class Switch : UISwitch
A UISwitch that handles its change event
-
Creates a UISwitch
Declaration
Swift
public init( isOn: Bool = false, toggleChanged: ((Bool) -> Void)? = nil )Parameters
isOnInitial value of the switch (Default: false)
toggleChangedClosure for the the switch’s change event (Default: nil)
View on GitHub
Switch Class Reference