The situation is that we want to replace some punctuations in a text string and we want to exploit POSIX code, \p{Punct}. However, we do not want to cover all punctuations in the \p{Punct} class. For example, we want to replace punctuations in the \p{Punct} class except ‘.’, ‘/’, ‘<’ and ‘>’ in an XML [...]
Filed under: Java | 2 Comments »