Take an example.
public static FieldsConfig getFieldsConfig(){
if(xxx) {
sssss;
}
return;
}
I write a regex, "\\s*public\\s*static.*getFieldsConfig\\(.*\\)\\s*\\{"
It can match only the first line. But how to match right to the last "}" of the method?
Help me. Thanks.
Edit: The content of method {} is not specified. But pattern is surely like this,
public static xxx theKnownMethodName(xxxx) {
xxxxxxx
}