MNAtomicBoolean

open class MNAtomicBoolean

Encapsulates a dispatch sempahore with boolean value

  • Declaration

    Swift

    public func get() -> Bool

    Return Value

    the value property

  • Gives a new value for the val property

    Declaration

    Swift

    public func set(_ val: Bool)

    Parameters

    val

    The new value for the val property

  • Negates the current value of the val property. Changes the value to false if currently true, changes it to true if current false.

    Declaration

    Swift

    public func toggle()