i have a source file something like
String some_words_come_here{
//some string lines
//some string lines
//some string lines
//some string lines
};
I am using it in java
Pattern.compile("(?m)^Strin.+\\};$", Pattern.MULTILINE | Pattern.DOTALL);
but this does not work well
with
Pattern.compile("(?m)^Strin.+", Pattern.MULTILINE);
i get the string just until the end of the line. because .+
is quitting at the end of the line.