Photoactive Core–Shell Nanorods as Bifunctional Electrodes for Boosting the Performance of Quantum Dot Sensitized Solar Cells and Photoelectrochemical Cells