Measurement of electrons from heavy-flavour hadron decays in p-Pb collisions at root s(NN)=5.02 TeV