I have a String, I need to split it with a comma, but if the previous character is \, then this part should not be splitted.
For example from String str = "first,second\\,third,fourth" i need String[] strs = { "first", "second\\,third", "fourth" }
Something like this?
look at the java.utils.regex.Pattern documentation for an explanation.