Monoid

public protocol Monoid : Semigroup

Interface defining objects with two methods:

  • Identity element
  • Composition operation (inherited from Semigroup).

Type Properties

  • Identity of Monoid.

    monoid <> identity = monoid
    

    Declaration

    Swift

    static var identity: Self { get }