格式化CSS文件,使之变成键值对形式

import java.util.ArrayList;
import java.util.HashMap;
import java.util.Map;

public class H {

	/**
	 * @param args
	 */
	public static void main(String[] args) {
		// TODO Auto-generated method stub
		 String s = ".add { background-image: url(../Image/fam/add.gif) !important;} .option{ background-image: url(../Image/fam/plugin.gif) !important;}";

		 ArrayList keyvalueList = new ArrayList();
		 Map map = new HashMap();
		 String result = null;
		// StringBuffer sb = new StringBuffer();
		 
		 int n=0;
		 for(int i = 0;i entry : map.entrySet())
		 {
			 System.out.println("Key = " + entry.getKey() + ", Value = " + entry.getValue());  
			 
		 }
		 
	}

}

格式化CSS,存入MAP中。

你可能感兴趣的:(JAVA相关)