Purpose of [^\x20-\x7E] in Regular Expressions

Purpose of [^\x20-\x7E] in Regular Expressions defines all characters that are not (^) in the range \x20-\x7E (hex 0x20 to 0x7E). According to http://www.asciitable.com/, those are characters from ‘space’ to ‘~’. Hence, given below Java code will work very efficiently:-

String updateMessage = message.replaceAll("[^\\x20-\\x7e]", "");

Happy Coding !!