KnowledgeHub
Questions
Tags
Users
Search
Alex Rivera
|
Logout
Edit Question
Title
Body
Why the following code not working(resulting false) with Indian languages? System.out.println(Charset.forName("UTF-8").encode("అనువాద") .asCharBuffer().toString().matches("\\p{L}+")); System.out.println(Charset.forName("UTF-8").encode("स्वागत") .asCharBuffer().toString().matches("\\p{L}+")); System.out.println(Charset.forName("UTF-8").encode("நல்வரவு") .asCharBuffer().toString().matches("\\p{L}+")); All the above code returns false. What is the problem with this regex? How to validate any unicode character in the world?
Tags (comma-separated)
Save Edits
Cancel