Map both value or error to a new type.
new expected with transformed value or error
Function handling the case when error is present.
Function handling the case when value is present.