Invariant
public protocol InvariantAn Invariant Functor provides a type the ability to transform its value type into another type. An instance of Functor or Contravariant are Invariant Functors as well.
- 
                  
                  Transforms the value type using the functions provided. The implementation of this function must obey the following laws: imap(fa, id, id) == fa imap(imap(fa, f1, g1), f2, g2) == imap(fa, compose(f2, f1), compose(g2, g1))DeclarationParametersfaValue whose value type will be transformed. fTransforming function. gTransforming function. Return ValueA new value in the same context as the original value, with the value type transformed. 
 
             Install in Dash
              Install in Dash
             Invariant Protocol Reference
        Invariant Protocol Reference