Threefold reactivity of a COF-embedded rhenium catalyst: reductive etherification, oxidative esterification or transfer hydrogenation.