String removeTemplatizedArgument(String str){
String cleanStr = "";
boolean withinTemplatized=false;
int countBlock = 0;
for(char x: str.toCharArray()){
if(x == '<'){
withinTemplatized = true;
countBlock++;
continue;
} else if(x == '>'){
withinTemplatized = false;
countBlock--;
continue;
} else if(!withinTemplatized && countBlock == 0){
cleanStr = cleanStr + x;
}
}
return cleanStr;
}
|