有誰知道當我存儲屬性文件時,冒號爲什麼越獄嗎?保存到屬性文件轉義:
我這樣做:
Properties prop = new Properties();
// Set the properties value.
prop.setProperty("url","http://localhost:7101/test/home");
並採用存儲:
prop.store(new FileOutputStream(propFile), null);
它的工作,但輸出已冒號逃過因某些原因:
url=http\://localhost\:7101/test/home
任何人都知道一個固定?
打倒我吧。教我適合首先編寫測試代碼,而不是去參加Javadoc。 – 2011-03-04 19:53:16
尊重編寫測試代碼! (讓你想知道爲什麼提出這個問題的人不會開始這樣做;) – iluxa 2011-03-04 20:05:10