StringEscapeUtils for character acceleration

where can I find this class StringEscapeUtils

that can automatically exit symbols instead of doing it manually ... in my search I found a utility named StringEscapeUtils

but I could not find in my project or I am trying to download from net but could not find too ... is there a way I can do that automate something like this:

String testStr = "< > \" &"; 
System.out.println("Escaped : " + StringEscapeUtils.escapeHtml(testStr)); 

      

+3


source to share


3 answers


You need to download the Apache Commons Lang library and include it in your project as a reference library.



+5


source


org.apache.commons.lang.StringEscapeUtils is part of the Apache Commons Lang package .



+1


source


+1


source