我有一个带有示例的字符串
• How are you. • I am fine. • ThirdLine.
现在我想检测所有 • 事件并存储在一个数组中。该数组将包含三个条目
•How are you
•I am fine
•ThirdLine
这怎么能在java中完成
您可以使用带有所需分隔符的Split ()方法
String[] splitted= line.split("\\•"); //line is your whole string
str = "• How are you. • I am fine. • ThirdLine.";
String[] list = str.split("\\•");