這裏是內容的Java屬性如何從Java屬性提取字符串
xxx_error_tx1 = This is xxxx. Johe say:
xxx_error_MapCode = xxx_error_tx1, test this function,Failed,\
Default, Current,\
App_Error_tx1
我需要提取字符串ID和字符串內容,我可以正確地提取第1行的內容,但第二行的內容只抽取第一個字符串xxx_error_tx1, test this function,Failed,\
。其餘的字符串不能提取。
正則表達式字符串是(?<ID>.+?)=(?<Translation>.+?)$
,我知道這個正則表達式有一些問題,但我試圖修改來糾正模式,但也許我是新手,結果仍然不能滿足我的要求。
任何幫助,將不勝感激。
可能重複[可.NET加載和分析屬性文件等同於Java屬性類?(http://stackoverflow.com/questions/485659/can-net-load-和-parse-a-properties-file-equivalent-to-java-properties-class) – Amadan 2014-11-25 05:01:32