private void chechIfExistWord(String line) {
String[] words = line.split(" ");
StringBuilder result = new StringBuilder();
for (String word : words) {
if(matchWord(word)) {
result.append(word.toUpperCase());
} else {
result.append(word);
}
}
}
private boolean matchWord(String word) {
return word.matches("\\p{Punct}*" + wordToModificate + "\\p{Punct}*");
}