I have a string (which is basically a file name following a naming convention) abc.def.ghi
I would like to extract the substring before the first
In java.lang.String you get some methods like indexOf(): which returns you first index of a char/string. and lstIndexOf: which returns you the last index of String/char
From Java Doc:
public int indexOf(int ch)
public int indexOf(String str)
Returns the index within this string of the first occurrence of the specified character.