It seems StringUtils.replaceEach in apache commons does what you want:
StringUtils.replaceEach("abcdeab", new String[]{"ab", "cd"}, new String[]{"cd", "ab"});
// returns "cdabecd"
Note that the documenent at the above links seems to be in error. See comments below for details.