爬虫解析之xls文件处理(附录甘肃省爬虫解析代码)

用jxl文件处理xls表格。突然发现if循环真的是感受到了温暖

package test;

import java.io.File;
import java.io.FileInputStream;
import java.io.FileWriter;
import java.io.IOException;

import jxl.Cell;
import jxl.Sheet;
import jxl.Workbook;

public class testXls {
	    /**
	     * 读取xls文件内容
	     * @param file 想要读取的文件对象
	     * @return 返回文件内容
	     */
	    public static String xls2String(File file){
		    
	        String result = "";
	        try{
	            FileInputStream fis = new FileInputStream(file);   
	            StringBuilder sb = new StringBuilder();   
	            jxl.Workbook rwb = Workbook.getWorkbook(fis);   
	            Sheet[] sheet = rwb.getSheets();
	            //System.out.println("表数目:"+sheet.length);
//	            for (int i = 0; i < sheet.length; i++) {   
//	                Sheet rs = rwb.getSheet(i);   
//	                for (int j = 0; j < rs.getRows(); j++) {   
//	                   Cell[] cells = rs.getRow(j);   
//	                   for(int k=0;k<cells.length;k++)   
//	                   sb.append(cells[k].getContents());   
//	                			}   
//	            			}   
	            
			String exportpath = "/home/hongw/桌面/m/0909";//输出所需要的内容至桌面上
			File exportfile = new File(exportpath);
			if(exportfile.exists())
			{   
				exportfile.delete();
			} 
			
		   Sheet rs = rwb.getSheet(0);
		   Cell[] sids = rs.getColumn(0);
		   Cell[] urls = rs.getColumn(6);
		   Cell[] citys = rs.getColumn(3);
		   Cell[] datasources = rs.getColumn(4);
		   
		   for(int i=0; i<urls.length; i++){
			    			//System.out.println(sids[i].getContents());
			    			//System.out.println(urls[i].getContents());
//				append(exportpath, " <requestparam id=\"" + sids[i].getContents() + "\" url=\"" + urls[i].getContents().replace("&", "&") + "\" method=\"" + "GET" + "\" charset=\"" + "utf-8" + 
//						"\" isSendJSON=\"" + "false" + "\">");
//				append(exportpath, "\n </requestparam>\n\n");
			   append(exportpath, "else if (entryurl.equals(\"" + urls[i].getContents() + "\")){\n");
			   append(exportpath, "    record.put(\"DATASOURCE\", \"" + datasources[i].getContents() +"\");\n");
			   append(exportpath, "    record.put(\"CITY\",\"" + citys[i].getContents() + "\");\n}");
				//}
			   
		    	}
	       System.out.println("ok");
	       
	       
	            fis.close();   
	            result += sb.toString();
	        }catch(Exception e){
	            e.printStackTrace();
	        		}
	        return result;
	    }
	    
	  public static void main(String[] args){
	      File file = new File("/home/qcli/桌面/0909.xls");//利用file读取桌面xls文件
	      xls2String(file);
	    }
	  
		public static int append(String fileName, String content) {  
			   try {  
			                       // 打开一个写文件器,构造函数中的第二个参数true表示以追加形式写文件  
			        FileWriter writer = new FileWriter(fileName, true);  
			        writer.write(content);  
			        writer.close();  
			        return 1;
			    } catch (IOException e) {  
			        e.printStackTrace();
			        return -1;
			   }  
		} 
}
利用jxl处理xls可以方便的获取xls文件中所需要的内容。

最终爬虫解析甘肃省是这样的~

	package com.amarsoft.court.app.process.imp.gansu;

	import java.util.List;
	import java.util.regex.Matcher;
	import java.util.regex.Pattern;

	import org.jsoup.Jsoup;
	import org.jsoup.nodes.Document;
	import org.jsoup.select.Elements;
	import org.jsoup.nodes.Element;

	import com.amardata.page.text.TextExtractFactory;
	import com.amardata.page.text.model.PdescModel;
	import com.amarsoft.are.ARE;
	import com.amarsoft.are.lang.StringX;
	import com.amarsoft.court.app.downloader.Downloader;
	import com.amarsoft.court.app.pojo.DataResource;
	import com.amarsoft.court.app.pojo.PageInfo;
	import com.amarsoft.court.app.pojo.PageInfoParseResult;
	import com.amarsoft.court.app.pojo.RequestParam;
	import com.amarsoft.court.app.process.PageInfoParse;
	import com.amarsoft.court.app.util.MatcherAssist;

	import net.sf.json.JSONArray;
	import net.sf.json.JSONObject;


	/**
甘vvvvgk15	甘肃省高级人民法院司法公开网	开庭公告	http://gsgf.gssfgk.com/ktgg/index.jhtml
甘lztlgk15	兰州铁路运输中级法院司法公开网	开庭公告	http://ltzy.gssfgk.com/ktgg.jhtml
甘jygvgk15	嘉峪关市中级人民法院司法公开网	开庭公告	http://jygzy.gssfgk.com/ktgg/index.jhtml
甘jyscgk15	嘉峪关市城区人民法院司法公开网	开庭公告	http://jygfy.gssfgk.com/ktgg.jhtml
甘jcvvgk15	金昌市中级人民法院司法公开网	开庭公告	http://jczy.gssfgk.com/ktgg.jhtml
甘jcjsgk15	金昌市金山区人民法院司法公开网	开庭公告	http://jcqfy.gssfgk.com/ktgg.jhtml
甘jcycgk15	永昌县人民法院司法公开网	开庭公告	http://ycfy.gssfgk.com/ktgg.jhtml
甘byvvgk15	白银市中级人民法院司法公开网	开庭公告	http://byzy.gssfgk.com/ktgg.jhtml
甘bypcgk15	平川区人民法院司法公开网	开庭公告	http://pcqfy.gssfgk.com/ktgg.jhtml
甘byhnrm15	会宁县人民法院	开庭公告	http://hnfy.gssfgk.com/ktgg.jhtml
甘byjtgk15	景泰县人民法院司法公开网	开庭公告	http://jtfy.gssfgk.com/ktgg/index.jhtml
甘bybygk15	白银区人民法院司法公开网	开庭公告	http://byqfy.gssfgk.com/ktgg.jhtml
甘tsvvgk15	天水市中级人民法院司法公开网	开庭公告	http://tszy.gssfgk.com/ktgg.jhtml
甘tsqzgk15	天水市秦州区人民法院司法公开网	开庭公告	http://qzqfy.gssfgk.com/ktgg.jhtml
甘tsmjgk15	天水市麦积区人民法院司法公开网	开庭公告	http://mjqfy.gssfgk.com/ktgg.jhtml
甘tsqagk15	天水市秦安县人民法院司法公开网	开庭公告	http://qafy.gssfgk.com/ktgg/index.jhtml
甘tsgggk15	天水市甘谷县人民法院司法公开网	开庭公告	http://ggfy.gssfgk.com/ktgg.jhtml
甘tswsgk15	天水市武山县人民法院司法公开网	开庭公告	http://wsfy.gssfgk.com/ktgg.jhtml
甘tszjgk15	天水市张家川回族自治县人民法院司法公开网	开庭公告	http://zjcfy.gssfgk.com/ktgg.jhtml
甘tsqsgk15	天水市清水县人民法院司法公开网	开庭公告	http://qsfy.gssfgk.com/ktgg.jhtml
甘wwvvgk15	武威市中级人民法院司法公开网	开庭公告	http://wyzy.gssfgk.com/ktgg/index.jhtml
甘wwlzgk15	武威市凉州区人民法院司法公开网	开庭公告	http://lzqfy.gssfgk.com/ktgg/index.jhtml
甘wwmlgk15	民勤县人民法院司法公开网	开庭公告	http://mqfy.gssfgk.com/ktgg/index.jhtml
甘wwglgk15	古浪县人民法院司法公开网	开庭公告	http://glfy.gssfgk.com/ktgg.jhtml
甘wwtzgk15	天祝藏族自治县人民法院司法公开网	开庭公告	http://tzfy.gssfgk.com/ktgg.jhtml
甘jqvvgk15	酒泉市中级人民法院司法公开网	开庭公告	http://jqzy.gssfgk.com/ktgg.jhtml
甘jqymgk15	玉门市人民法院司法公开网	开庭公告	http://ymfy.gssfgk.com/ktgg.jhtml
甘jqszgk15	酒泉市肃州区人民法院司法公开网	开庭公告	http://szqfy.gssfgk.com/ktgg/index.jhtml
甘jqdhgk15	敦煌市人民法院司法公开网	开庭公告	http://dhfy.gssfgk.com/ktgg.jhtml
甘jqjtgk15	金塔县人民法院司法公开网	开庭公告	http://jtxy.gssfgk.com/ktgg/index.jhtml
甘zyvvgk15	张掖市中级人民法院司法公开网	开庭公告	http://zyzy.gssfgk.com/ktgg.jhtml
甘zygzgk15	张掖市甘州区人民法院司法公开网	开庭公告	http://gzqfy.gssfgk.com/ktgg.jhtml
甘zysngk15	肃南裕固族自治县人民法院司法公开网	开庭公告	http://snfy.gssfgk.com/ktgg.jhtml
甘zymlgk15	民乐县人民法院司法公开网	开庭公告	http://mlfy.gssfgk.com/ktgg.jhtml
甘zyzjgk15	临泽县人民法院司法公开网	开庭公告	http://lzfy.gssfgk.com/ktgg.jhtml
甘zygtgk15	高台县人民法院司法公开网	开庭公告	http://gtfy.gssfgk.com/ktgg.jhtml
甘zysdgk15	山丹县人民法院司法公开网	开庭公告	http://sdfy.gssfgk.com/ktgg/index.jhtml
甘qyvvgk15	庆阳市中级人民法院司法公开网	开庭公告	http://qyzy.gssfgk.com/ktgg.jhtml
甘qyxfgk15	庆阳市西峰区人民法院司法公开网	开庭公告	http://xfqfy.gssfgk.com/ktgg.jhtml
甘qyqcgk15	庆城县人民法院司法公开网	开庭公告	http://qcfy.gssfgk.com/ktgg.jhtml
甘qyhxgk15	环县人民法院司法公开网	开庭公告	http://hxfy.gssfgk.com/ktgg.jhtml
甘qyhcgk15	华池县人民法院司法公开网	开庭公告	http://hcfy.gssfgk.com/ktgg.jhtml
甘qyzngk15	正宁县人民法院司法公开网	开庭公告	http://znfy.gssfgk.com/ktgg.jhtml
甘qynxgk15	宁县人民法院司法公开网	开庭公告	http://nxfy.gssfgk.com/ktgg.jhtml
甘qylqgk15	庆阳林区基层法院司法公开网	开庭公告	http://qylqfy.gssfgk.com/ktgg.jhtml
甘plvvgk15	平凉市中级人民法院司法公开网	开庭公告	http://plzy.gssfgk.com/ktgg/index.jhtml
甘pljcgk15	泾川县人民法院司法公开网	开庭公告	http://jcfy.gssfgk.com/ktgg.jhtml
甘plltgk15	灵台县人民法院司法公开网	开庭公告	http://ltfy.gssfgk.com/ktgg.jhtml
甘plcxgk15	崇信县人民法院司法公开网	开庭公告	http://cxxy.gssfgk.com/ktgg.jhtml
甘plhtgk15	华亭县人民法院司法公开网	开庭公告	http://htfy.gssfgk.com/ktgg.jhtml
甘plzlgk15	庄浪县人民法院司法公开网	开庭公告	http://zlfy.gssfgk.com/ktgg.jhtml
甘pljngk15	静宁县人民法院司法公开网	开庭公告	http://jnfy.gssfgk.com/ktgg.jhtml
甘plktgk15	平凉市崆峒区人民法院司法公开网	开庭公告	http://ktqfy.gssfgk.com/ktgg.jhtml
甘lnvvgk15	陇南市中级人民法院司法公开网	开庭公告	http://lnzy.gssfgk.com/ktgg.jhtml
甘lnwdgk15	陇南市武都区人民法院司法公开网	开庭公告	http://wdqfy.gssfgk.com/ktgg.jhtml
甘lndcgk15	宕昌县人民法院司法公开网	开庭公告	http://tcfy.gssfgk.com/ktgg.jhtml
甘lncxgk15	成县人民法院司法公开网	开庭公告	http://cxfy.gssfgk.com/ktgg.jhtml
甘lnwxgk15	文县人民法院司法公开网	开庭公告	http://wxfy.gssfgk.com/ktgg/index.jhtml
甘lnxhgk15	西和县人民法院司法公开网	开庭公告	http://xhfy.gssfgk.com/ktgg.jhtml
甘lnlxgk15	礼县人民法院司法公开网	开庭公告	http://lxfy.gssfgk.com/ktgg.jhtml
甘lnldgk15	两当县人民法院司法公开网	开庭公告	http://ldfy.gssfgk.com/ktgg.jhtml
甘lnhxgk15	徽县人民法院司法公开网	开庭公告	http://wxxy.gssfgk.com/ktgg.jhtml
甘lxhzrm15	临夏回族自治州人民法院	开庭公告	http://lxzy.gssfgk.com/ktgg.jhtml
甘lxvvgk15	临夏市人民法院司法公开网	开庭公告	http://lxsfy.gssfgk.com/ktgg.jhtml
甘lxlxgk15	临夏县人民法院司法公开网	开庭公告	http://lxxy.gssfgk.com/ktgg.jhtml
甘lxklgk15	康乐县人民法院司法公开网	开庭公告	http://klfy.gssfgk.com/ktgg.jhtml
甘lxyjgk15	永靖县人民法院司法公开网	开庭公告	http://yjfy.gssfgk.com/ktgg.jhtml
甘lxghgk15	广河县人民法院司法公开网	开庭公告	http://ghfy.gssfgk.com/ktgg.jhtml
甘lxhzgk15	和政县人民法院司法公开网	开庭公告	http://hzfy.gssfgk.com/ktgg.jhtml
甘lxjsrm15	积石山保安族东乡族撒拉族自治县人民法院	开庭公告	http://jssfy.gssfgk.com/ktgg.jhtml
甘gngngk15	甘南藏族自治州人民法院司法公开网	开庭公告	http://gnzy.gssfgk.com/ktgg.jhtml
甘gnltgk15	临潭县人民法院司法公开网	开庭公告	http://ltxy.gssfgk.com/ktgg.jhtml
甘gnzngk15	卓尼县人民法院司法公开网	开庭公告	http://znxy.gssfgk.com/ktgg.jhtml

	 * @author ytwang
	 * */

	public class GSaggregateCourtListParseImpl implements PageInfoParse{
		private int listsize;
		private String entryurl;
		private String tarurl;
		
		public PageInfoParseResult parsePageInfo(PageInfo pageInfo, Downloader downloader){
			System.out.println(parseTotalPage(pageInfo));
			String html = pageInfo.getRawText();
			Document doc = Jsoup.parse(html);
			DataResource dataResource = pageInfo.getDataResource();
			PageInfoParseResult result = new PageInfoParseResult();
			result.setDataResource(dataResource);
			RequestParam requestParam=pageInfo.getRequestParam();
			Elements lis = doc.select("div[class=text]").first().select("li");
		  //System.out.println("获取的列表内容位:"+lis);
	    //System.out.println(lis.size());
		  //System.exit(0);
			
			if (lis == null || lis.size() < 1) {
				ARE.getLog().info("没有获取到数据源[" + dataResource.getDataResourceName() + "]的数据");
				return result;
			}
			JSONArray records = new JSONArray();
			String content=null;
			String contentUrl="";
			for (int i = 0; i < lis.size(); i++){
				Element href = lis.get(i).select("a").first();
				//Element hreftime=lis.get(i).select("div[class=text]").select("li").first();
				String target=href.text();//标题
				//String pDate=hreftime.text();//发布时间
				//System.out.println(target);
				//System.out.println(pDate);
				//System.exit(0);
	
				ARE.getLog().debug("测试甘肃省网页解析"+href.text());

	    String url=contentUrl+href.attr("href");

	     requestParam.setRequestUrl(url);			
				requestParam.setRequestMethod("GET");
				
				
				try {
					PageInfo pageDetailInfo = downloader.download(requestParam, dataResource);//下载页面详情
					content = pageDetailInfo.getRawText();
					if (content == null || content.trim().isEmpty()) {
						continue;
					}	
				
					//html>body>table>tbody>tr>td>div>table>tbody>tr>td>table>tbody>tr>td>table>tbody>tr>td>span>table>tbody>tr>td
					//html>body>table>tbody>tr>td>div>table>tbody>tr>td>table>tbody>tr>td>table>tbody>tr>td>span>p
					String path=MatcherAssist.FindPath2(content,"我院");
				  //System.out.println("路径为"+path);
					path="html>body>div>div>div>div>div.text";

					List<PdescModel> resultList = TextExtractFactory.getTextExtract().getExtractedList(content, path);
					//System.out.println(resultList.size());
					int n=0;
					for(PdescModel res:resultList)
					{
						
						String caseDate=res.getCasedate();
						String pDesc=res.getPdesc();
						String pDate = "";  
						pDate=pDesc.substring(pDesc.indexOf(":"),pDesc.indexOf("     作"));
						caseDate=pDesc.substring(pDesc.indexOf("20"),pDesc.indexOf("日"));
						//System.out.println("原始时间为:"+caseDate);
						pDate=timeConvert("",pDate);
						caseDate=timeConvert("",caseDate);
					 //caseDate=timeConvert(pDate,caseDate);
						System.out.println(caseDate+pDesc);
					  System.out.println(pDate);
				   JSONObject record = new JSONObject();
				
                jsonobjectInit(record);
                record.put("PROVINCE", "甘肃省");
              record.put("NOTICEADDR",url+(n++));
                record.put("TARGET", target);
              record.put("PDATE", pDate);
                record.put("CASEDATE", caseDate);
                record.put("PDESC", pDesc);
record.put("type",15 )
                records.add(record);

				
					}
				}catch(Exception e){
					ARE.getLog().error("获取数据源["+dataResource.getDataResourceName()+"]中url["+url+"]的详情数据时出现异常",e);
					continue;
				}

			}
			ARE.getLog().debug("查询爬取后的数据:"+records.toString());
			try {
				Thread.sleep(2000);
			} catch (InterruptedException e) {
				e.printStackTrace();
			}
			result.setRecords(records);
			return result;
		}
		public static String timeConvert(String pDate, String brTime){
				Pattern p1 = Pattern.compile("\\d{4}(\\-|\\/|.)\\d{1,2}\\1\\d{1,2}");
				Matcher m1 = p1.matcher(brTime);
				if(m1.find()){
					brTime = m1.group();
					brTime = brTime.replaceAll("-", "/");
				}else{
					Pattern p3 = Pattern.compile("\\d{4}");
					Matcher m3 = p3.matcher(pDate);
					String year = "";
					if(m3.find()){
						year = m3.group();
					}
					Pattern p2 = Pattern.compile("\\d{4}+年\\d+月\\d+");
					Matcher m2 = p2.matcher(brTime);
					String brMonth = "";
					if(m2.find())
					brMonth = m2.group();
					brMonth = brMonth.replace("年", "/");
					brMonth = brMonth.replace("日", "");
					brMonth = brMonth.replace("月", "/");
					brMonth = brMonth.replace("-", "");
					brTime = year+"/"+brMonth;	
				}
				return brTime;
			}
	public List<String> parseTargetRequestUrl(PageInfo pageInfo) {
			return null;
		}

	public int parseTotalPage(PageInfo pageInfo) {
		// TODO Auto-generated method stub
		String htmlStr = pageInfo.getRawText();
		//System.out.println(htmlStr);
		int Pages = 1;
		String TmpStr = MatcherAssist.getMatcherStr(htmlStr, "&listsize=\\d+&");
		//System.out.println("页数为:"+ TmpStr);
		String PageNumStr = MatcherAssist.getMatcherStr(TmpStr, "\\d+");
		//System.out.println("页数为:"+ PageNumStr);
		if(PageNumStr.length()==0)
			ARE.getLog().debug("获取总页数失败");
		else {
			Pages = Integer.parseInt(PageNumStr);
			listsize = Pages;
		}
		RequestParam requestParamN = pageInfo.getRequestParam();
		String url = MatcherAssist.getMatcherStr(htmlStr, "\".+&listsize=\\d+&.+\"");
		if (url.length() == 0)
			ARE.getLog().debug("获取入口URL失败");
		else{
			entryurl = requestParamN.getRequestUrl();
			tarurl = "http://" + requestParamN.getRequestUrl().split("/")[2] + url.split("\"")[1];
		}
		return Pages;
	}
	
	public String getNextTargetRequestUrl(PageInfo pageInfo, int nextPage) {
		// TODO Auto-generated method stub
			return tarurl.replaceAll("pagego=\\d+", "pagego=" + nextPage);
	}
	public void jsonobjectInit(JSONObject record){
		record.put("PDATE", "");
		record.put("TARGET", "");
		record.put("NOTICEADDR", "");
		record.put("PTYPE", "15");
		record.put("CASEDATE", "");
		record.put("COURT", "");
		record.put("PDESC", "");
		record.put("PROVINCE", "甘肃省");
		if (entryurl.equals("http://gsgf.gssfgk.com/ktgg/index.jhtml")){
			 record.put("DATASOURCE", "甘肃省高级人民法院司法公开网");
			 record.put("CITY", "");
			 record.put("COURT", "甘肃省高级人民法院");
		}else if (entryurl.equals("http://ltzy.gssfgk.com/ktgg.jhtml")){
		    record.put("DATASOURCE", "兰州铁路运输中级法院司法公开网");
		    record.put("CITY","兰州市");
			  record.put("COURT", "兰州铁路运输中级法院");
		}else if (entryurl.equals("http://jygzy.gssfgk.com/ktgg/index.jhtml")){
		    record.put("DATASOURCE", "嘉峪关市中级人民法院司法公开网");
		    record.put("CITY","嘉峪关市");
		    record.put("COURT", "嘉峪关市中级人民法院");
		 }else if (entryurl.equals("http://jygfy.gssfgk.com/ktgg.jhtml")){
			    record.put("DATASOURCE", "嘉峪关市城区人民法院司法公开网");
			    record.put("CITY","嘉峪关市");
			    record.put("COURT","嘉峪关市城区人民法院");
			}else if (entryurl.equals("http://jczy.gssfgk.com/ktgg.jhtml")){
			    record.put("DATASOURCE", "金昌市中级人民法院司法公开网");
			    record.put("CITY","金昌市");
			    record.put("COURT","金昌市中级人民法院");
			}else if (entryurl.equals("http://jcqfy.gssfgk.com/ktgg.jhtml")){
			    record.put("DATASOURCE", "金昌市金山区人民法院司法公开网");
			    record.put("CITY","金昌市");
			    record.put("COURT","金昌市金山区人民法院");
			}else if (entryurl.equals("http://ycfy.gssfgk.com/ktgg.jhtml")){
			    record.put("DATASOURCE", "永昌县人民法院司法公开网");
			    record.put("CITY","金昌市");
			    record.put("COURT","永昌县人民法院");
			}else if (entryurl.equals("http://byzy.gssfgk.com/ktgg.jhtml")){
			    record.put("DATASOURCE", "白银市中级人民法院司法公开网");
			    record.put("CITY","白银市");
			    record.put("COURT","白银市中级人民法院");
			}else if (entryurl.equals("http://pcqfy.gssfgk.com/ktgg.jhtml")){
			    record.put("DATASOURCE", "平川区人民法院司法公开网");
			    record.put("CITY","白银市");
			    record.put("COURT","平川区人民法院");
			}else if (entryurl.equals("http://hnfy.gssfgk.com/ktgg.jhtml")){
			    record.put("DATASOURCE", "会宁县人民法院");
			    record.put("CITY","白银市");
			    record.put("COURT","会宁县人民法院");
			}else if (entryurl.equals("http://jtfy.gssfgk.com/ktgg/index.jhtml")){
			    record.put("DATASOURCE", "景泰县人民法院司法公开网");
			    record.put("CITY","白银市");
			    record.put("COURT","景泰县人民法院");
			}else if (entryurl.equals("http://byqfy.gssfgk.com/ktgg.jhtml")){
			    record.put("DATASOURCE", "白银区人民法院司法公开网");
			    record.put("CITY","白银市");
			    record.put("COURT","白银区人民法院");
			}else if (entryurl.equals("http://tszy.gssfgk.com/ktgg.jhtml")){
			    record.put("DATASOURCE", "天水市中级人民法院司法公开网");
			    record.put("CITY","天水市");
			    record.put("COURT","天水市中级人民法院");
			}else if (entryurl.equals("http://qzqfy.gssfgk.com/ktgg.jhtml")){
			    record.put("DATASOURCE", "天水市秦州区人民法院司法公开网");
			    record.put("CITY","天水市");
			    record.put("COURT","天水市秦州区人民法院");
			}else if (entryurl.equals("http://mjqfy.gssfgk.com/ktgg.jhtml")){
			    record.put("DATASOURCE", "天水市麦积区人民法院司法公开网");
			    record.put("CITY","天水市");
			    record.put("COURT","天水市麦积区人民法院");
			}else if (entryurl.equals("http://qafy.gssfgk.com/ktgg/index.jhtml")){
			    record.put("DATASOURCE", "天水市秦安县人民法院司法公开网");
			    record.put("CITY","天水市");
			    record.put("COURT","天水市秦安县人民法院");
			}else if (entryurl.equals("http://ggfy.gssfgk.com/ktgg.jhtml")){
			    record.put("DATASOURCE", "天水市甘谷县人民法院司法公开网");
			    record.put("CITY","天水市");
			    record.put("COURT","天水市甘谷县人民法院");
			}else if (entryurl.equals("http://wsfy.gssfgk.com/ktgg.jhtml")){
			    record.put("DATASOURCE", "天水市武山县人民法院司法公开网");
			    record.put("CITY","天水市");
			    record.put("COURT","天水市武山县人民法院");
			}else if (entryurl.equals("http://zjcfy.gssfgk.com/ktgg.jhtml")){
			    record.put("DATASOURCE", "天水市张家川回族自治县人民法院司法公开网");
			    record.put("CITY","天水市");
			    record.put("COURT","天水市张家川回族自治县人民法院");
			}else if (entryurl.equals("http://qsfy.gssfgk.com/ktgg.jhtml")){
			    record.put("DATASOURCE", "天水市清水县人民法院司法公开网");
			    record.put("CITY","天水市");
			    record.put("COURT","天水市清水县人民法院");
			}else if (entryurl.equals("http://wyzy.gssfgk.com/ktgg/index.jhtml")){
			    record.put("DATASOURCE", "武威市中级人民法院司法公开网");
			    record.put("CITY","武威市");
			    record.put("COURT","武威市中级人民法院");
			}else if (entryurl.equals("http://lzqfy.gssfgk.com/ktgg/index.jhtml")){
			    record.put("DATASOURCE", "武威市凉州区人民法院司法公开网");
			    record.put("CITY","武威市");
			    record.put("COURT","武威市凉州区人民法院");
			}else if (entryurl.equals("http://mqfy.gssfgk.com/ktgg/index.jhtml")){
			    record.put("DATASOURCE", "民勤县人民法院司法公开网");
			    record.put("CITY","武威市");
			    record.put("COURT","民勤县人民法院");
			}else if (entryurl.equals("http://glfy.gssfgk.com/ktgg.jhtml")){
			    record.put("DATASOURCE", "古浪县人民法院司法公开网");
			    record.put("CITY","武威市");
			    record.put("COURT","古浪县人民法院");
			}else if (entryurl.equals("http://tzfy.gssfgk.com/ktgg.jhtml")){
			    record.put("DATASOURCE", "天祝藏族自治县人民法院司法公开网");
			    record.put("CITY","武威市");
			    record.put("COURT","天祝藏族自治县人民法院");
			}else if (entryurl.equals("http://jqzy.gssfgk.com/ktgg.jhtml")){
			    record.put("DATASOURCE", "酒泉市中级人民法院司法公开网");
			    record.put("CITY","酒泉市");
			    record.put("COURT","酒泉市中级人民法院");
			}else if (entryurl.equals("http://ymfy.gssfgk.com/ktgg.jhtml")){
			    record.put("DATASOURCE", "玉门市人民法院司法公开网");
			    record.put("CITY","酒泉市");
			    record.put("COURT","玉门市人民法院");
			}else if (entryurl.equals("http://szqfy.gssfgk.com/ktgg/index.jhtml")){
			    record.put("DATASOURCE", "酒泉市肃州区人民法院司法公开网");
			    record.put("CITY","酒泉市");
			    record.put("COURT","酒泉市肃州区人民法院");
			}else if (entryurl.equals("http://dhfy.gssfgk.com/ktgg.jhtml")){
			    record.put("DATASOURCE", "敦煌市人民法院司法公开网");
			    record.put("CITY","酒泉市");
			    record.put("COURT","敦煌市人民法院");
			}else if (entryurl.equals("http://jtxy.gssfgk.com/ktgg/index.jhtml")){
			    record.put("DATASOURCE", "金塔县人民法院司法公开网");
			    record.put("CITY","酒泉市");
			    record.put("COURT","金塔县人民法院");
			}else if (entryurl.equals("http://zyzy.gssfgk.com/ktgg.jhtml")){
			    record.put("DATASOURCE", "张掖市中级人民法院司法公开网");
			    record.put("CITY","张掖市");
			    record.put("COURT","张掖市中级人民法院");
			}else if (entryurl.equals("http://gzqfy.gssfgk.com/ktgg.jhtml")){
			    record.put("DATASOURCE", "张掖市甘州区人民法院司法公开网");
			    record.put("CITY","张掖市");
			    record.put("COURT","张掖市甘州区人民法院");
			}else if (entryurl.equals("http://snfy.gssfgk.com/ktgg.jhtml")){
			    record.put("DATASOURCE", "肃南裕固族自治县人民法院司法公开网");
			    record.put("CITY","张掖市");
			    record.put("COURT","肃南裕固族自治县人民法院");
			}else if (entryurl.equals("http://mlfy.gssfgk.com/ktgg.jhtml")){
			    record.put("DATASOURCE", "民乐县人民法院司法公开网");
			    record.put("CITY","张掖市");
			    record.put("COURT","民乐县人民法院");
			}else if (entryurl.equals("http://lzfy.gssfgk.com/ktgg.jhtml")){
			    record.put("DATASOURCE", "临泽县人民法院司法公开网");
			    record.put("CITY","张掖市");
			    record.put("COURT","临泽县人民法院");
			}else if (entryurl.equals("http://gtfy.gssfgk.com/ktgg.jhtml")){
			    record.put("DATASOURCE", "高台县人民法院司法公开网");
			    record.put("CITY","张掖市");
			    record.put("COURT","高台县人民法院");
			}else if (entryurl.equals("http://sdfy.gssfgk.com/ktgg/index.jhtml")){
			    record.put("DATASOURCE", "山丹县人民法院司法公开网");
			    record.put("CITY","张掖市");
			    record.put("COURT","山丹县人民法院");
			}else if (entryurl.equals("http://qyzy.gssfgk.com/ktgg.jhtml")){
			    record.put("DATASOURCE", "庆阳市中级人民法院司法公开网");
			    record.put("CITY","庆阳市");
			    record.put("COURT","庆阳市中级人民法院");
			}else if (entryurl.equals("http://xfqfy.gssfgk.com/ktgg.jhtml")){
			    record.put("DATASOURCE", "庆阳市西峰区人民法院司法公开网");
			    record.put("CITY","庆阳市");
			    record.put("COURT","庆阳市西峰区人民法院");
			}else if (entryurl.equals("http://qcfy.gssfgk.com/ktgg.jhtml")){
			    record.put("DATASOURCE", "庆城县人民法院司法公开网");
			    record.put("CITY","庆阳市");
			    record.put("COURT","庆城县人民法院");
			}else if (entryurl.equals("http://hxfy.gssfgk.com/ktgg.jhtml")){
			    record.put("DATASOURCE", "环县人民法院司法公开网");
			    record.put("CITY","庆阳市");
			    record.put("COURT","环县人民法院");
			}else if (entryurl.equals("http://hcfy.gssfgk.com/ktgg.jhtml")){
			    record.put("DATASOURCE", "华池县人民法院司法公开网");
			    record.put("CITY","庆阳市");
			    record.put("COURT","华池县人民法院");
			}else if (entryurl.equals("http://znfy.gssfgk.com/ktgg.jhtml")){
			    record.put("DATASOURCE", "正宁县人民法院司法公开网");
			    record.put("CITY","庆阳市");
			    record.put("COURT","正宁县人民法院");
			}else if (entryurl.equals("http://nxfy.gssfgk.com/ktgg.jhtml")){
			    record.put("DATASOURCE", "宁县人民法院司法公开网");
			    record.put("CITY","庆阳市");
			    record.put("COURT","宁县人民法院");
			}else if (entryurl.equals("http://qylqfy.gssfgk.com/ktgg.jhtml")){
			    record.put("DATASOURCE", "庆阳林区基层法院司法公开网");
			    record.put("CITY","庆阳市");
			    record.put("COURT","庆阳林区基层法院");
			}else if (entryurl.equals("http://plzy.gssfgk.com/ktgg/index.jhtml")){
			    record.put("DATASOURCE", "平凉市中级人民法院司法公开网");
			    record.put("CITY","平凉市");
			    record.put("COURT","平凉市中级人民法院");
			}else if (entryurl.equals("http://jcfy.gssfgk.com/ktgg.jhtml")){
			    record.put("DATASOURCE", "泾川县人民法院司法公开网");
			    record.put("CITY","平凉市");
			    record.put("COURT","泾川县人民法院");
			}else if (entryurl.equals("http://ltfy.gssfgk.com/ktgg.jhtml")){
			    record.put("DATASOURCE", "灵台县人民法院司法公开网");
			    record.put("CITY","平凉市");
			    record.put("COURT","灵台县人民法院");
			}else if (entryurl.equals("http://cxxy.gssfgk.com/ktgg.jhtml")){
			    record.put("DATASOURCE", "崇信县人民法院司法公开网");
			    record.put("CITY","平凉市");
			    record.put("COURT","崇信县人民法院");
			}else if (entryurl.equals("http://htfy.gssfgk.com/ktgg.jhtml")){
			    record.put("DATASOURCE", "华亭县人民法院司法公开网");
			    record.put("CITY","平凉市");
			    record.put("COURT","华亭县人民法院");
			}else if (entryurl.equals("http://zlfy.gssfgk.com/ktgg.jhtml")){
			    record.put("DATASOURCE", "庄浪县人民法院司法公开网");
			    record.put("CITY","平凉市");
			    record.put("COURT","庄浪县人民法院");
			}else if (entryurl.equals("http://jnfy.gssfgk.com/ktgg.jhtml")){
			    record.put("DATASOURCE", "静宁县人民法院司法公开网");
			    record.put("CITY","平凉市");
			    record.put("COURT","静宁县人民法院");
			}else if (entryurl.equals("http://ktqfy.gssfgk.com/ktgg.jhtml")){
			    record.put("DATASOURCE", "平凉市崆峒区人民法院司法公开网");
			    record.put("CITY","平凉市");
			    record.put("COURT","平凉市崆峒区人民法院");
			}else if (entryurl.equals("http://lnzy.gssfgk.com/ktgg.jhtml")){
			    record.put("DATASOURCE", "陇南市中级人民法院司法公开网");
			    record.put("CITY","陇南市");
			    record.put("COURT","陇南市中级人民法院");
			}else if (entryurl.equals("http://wdqfy.gssfgk.com/ktgg.jhtml")){
			    record.put("DATASOURCE", "陇南市武都区人民法院司法公开网");
			    record.put("CITY","陇南市");
			    record.put("COURT","陇南市武都区人民法院");
			}else if (entryurl.equals("http://tcfy.gssfgk.com/ktgg.jhtml")){
			    record.put("DATASOURCE", "宕昌县人民法院司法公开网");
			    record.put("CITY","陇南市");
			    record.put("COURT","宕昌县人民法院");
			}else if (entryurl.equals("http://cxfy.gssfgk.com/ktgg.jhtml")){
			    record.put("DATASOURCE", "成县人民法院司法公开网");
			    record.put("CITY","陇南市");
			    record.put("COURT","成县人民法院");
			}else if (entryurl.equals("http://wxfy.gssfgk.com/ktgg/index.jhtml")){
			    record.put("DATASOURCE", "文县人民法院司法公开网");
			    record.put("CITY","陇南市");
			    record.put("COURT","文县人民法院");
			}else if (entryurl.equals("http://xhfy.gssfgk.com/ktgg.jhtml")){
			    record.put("DATASOURCE", "西和县人民法院司法公开网");
			    record.put("CITY","陇南市");
			    record.put("COURT","西和县人民法院");
			}else if (entryurl.equals("http://lxfy.gssfgk.com/ktgg.jhtml")){
			    record.put("DATASOURCE", "礼县人民法院司法公开网");
			    record.put("CITY","陇南市");
			    record.put("COURT","礼县人民法院");
			}else if (entryurl.equals("http://ldfy.gssfgk.com/ktgg.jhtml")){
			    record.put("DATASOURCE", "两当县人民法院司法公开网");
			    record.put("CITY","陇南市");
			    record.put("COURT","两当县人民法院");
			}else if (entryurl.equals("http://wxxy.gssfgk.com/ktgg.jhtml")){
			    record.put("DATASOURCE", "徽县人民法院司法公开网");
			    record.put("CITY","陇南市");
			    record.put("COURT","徽县人民法院");
			}else if (entryurl.equals("http://lxzy.gssfgk.com/ktgg.jhtml")){
			    record.put("DATASOURCE", "临夏回族自治州人民法院");
			    record.put("CITY","临夏州");
			    record.put("COURT","临夏回族自治州人民法院");
			}else if (entryurl.equals("http://lxsfy.gssfgk.com/ktgg.jhtml")){
			    record.put("DATASOURCE", "临夏市人民法院司法公开网");
			    record.put("CITY","临夏州");
			    record.put("COURT","临夏市人民法院");
			}else if (entryurl.equals("http://lxxy.gssfgk.com/ktgg.jhtml")){
			    record.put("DATASOURCE", "临夏县人民法院司法公开网");
			    record.put("CITY","临夏州");
			    record.put("COURT","临夏县人民法院");
			}else if (entryurl.equals("http://klfy.gssfgk.com/ktgg.jhtml")){
			    record.put("DATASOURCE", "康乐县人民法院司法公开网");
			    record.put("CITY","临夏州");
			    record.put("COURT","康乐县人民法院");
			}else if (entryurl.equals("http://yjfy.gssfgk.com/ktgg.jhtml")){
			    record.put("DATASOURCE", "永靖县人民法院司法公开网");
			    record.put("CITY","临夏州");
			    record.put("COURT","永靖县人民法院");
			}else if (entryurl.equals("http://ghfy.gssfgk.com/ktgg.jhtml")){
			    record.put("DATASOURCE", "广河县人民法院司法公开网");
			    record.put("CITY","临夏州");
			    record.put("COURT","广河县人民法院");
			}else if (entryurl.equals("http://hzfy.gssfgk.com/ktgg.jhtml")){
			    record.put("DATASOURCE", "和政县人民法院司法公开网");
			    record.put("CITY","临夏州");
			    record.put("COURT","和政县人民法院");
			}else if (entryurl.equals("http://jssfy.gssfgk.com/ktgg.jhtml")){
			    record.put("DATASOURCE", "积石山保安族东乡族撒拉族自治县人民法院");
			    record.put("CITY","临夏州");
			    record.put("COURT","积石山保安族东乡族撒拉族自治县人民法院");
			}else if (entryurl.equals("http://gnzy.gssfgk.com/ktgg.jhtml")){
			    record.put("DATASOURCE", "甘南藏族自治州人民法院司法公开网");
			    record.put("CITY","甘南州");
			    record.put("COURT","甘南藏族自治州人民法院");
			}else if (entryurl.equals("http://ltxy.gssfgk.com/ktgg.jhtml")){
			    record.put("DATASOURCE", "临潭县人民法院司法公开网");
			    record.put("CITY","甘南州");
			    record.put("COURT","临潭县人民法院");
			}else if (entryurl.equals("http://znxy.gssfgk.com/ktgg.jhtml")){
			    record.put("DATASOURCE", "卓尼县人民法院司法公开网");
			    record.put("CITY","甘南州");
			    record.put("COURT","卓尼县人民法院");
			}
			
		
	}
	

	}


猜你喜欢

转载自blog.csdn.net/qq_26925867/article/details/52574830