Man sentenced over rape of sex worker