Some would say, i have 3 problems 😉
private final static Pattern placeholder = Pattern.compile("#\\{(\\w+?)\\}"); |
won’t match “Mot#{ö}rhead” for example.
To replace the word character \w you either need the list of possible unicodeblocks like [\p{InLatin}|\p{InEtc}] (you get the codes for the blocks through “Character.UnicodeBlock.forName” or you’re lazy like me and just use the dot:
private final static Pattern placeholder = Pattern.compile("#\\{(.+?)\\}"); |
Oh what a day… :/
No comments yet
Post a Comment