0

How can i convert HTML symbol to Java symbol? For example: I have &#xe000 String and i need Java char like \ue000. What i need to do?

Procurares
  • 2,169
  • 4
  • 22
  • 34

2 Answers2

1

Try unescapeHtml4 from the Apache Commons toolkit.

nneonneo
  • 171,345
  • 36
  • 312
  • 383
  • How can i use it in Android, i need to install some additional library? – Procurares Feb 17 '13 at 00:58
  • 1
    See http://stackoverflow.com/questions/2146870/importing-org-apache-commons-into-android-applications. Yes, it's an additional library, but it has so much useful stuff you'll want to keep using it ;) – nneonneo Feb 17 '13 at 01:01
0

I found better solution in Android. I just call static method Html.fromHtml("&#xe000"), and the given result wat another String in Java source format like \ue000.

Procurares
  • 2,169
  • 4
  • 22
  • 34