﻿<?xml version="1.0" encoding="utf-8" standalone="yes"?><rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:trackback="http://madskills.com/public/xml/rss/module/trackback/" xmlns:wfw="http://wellformedweb.org/CommentAPI/" xmlns:slash="http://purl.org/rss/1.0/modules/slash/"><channel><title>语源科技BlogJava-lyyb2001</title><link>http://www.blogjava.net/lyyb2001/</link><description>只是为方便自己找记录而已</description><language>zh-cn</language><lastBuildDate>Sun, 03 May 2026 04:31:01 GMT</lastBuildDate><pubDate>Sun, 03 May 2026 04:31:01 GMT</pubDate><ttl>60</ttl><item><title>easyui validate对单个输入框的验证</title><link>http://www.blogjava.net/lyyb2001/archive/2017/09/19/432827.html</link><dc:creator>skycity</dc:creator><author>skycity</author><pubDate>Tue, 19 Sep 2017 07:59:00 GMT</pubDate><guid>http://www.blogjava.net/lyyb2001/archive/2017/09/19/432827.html</guid><wfw:comment>http://www.blogjava.net/lyyb2001/comments/432827.html</wfw:comment><comments>http://www.blogjava.net/lyyb2001/archive/2017/09/19/432827.html#Feedback</comments><slash:comments>0</slash:comments><wfw:commentRss>http://www.blogjava.net/lyyb2001/comments/commentRss/432827.html</wfw:commentRss><trackback:ping>http://www.blogjava.net/lyyb2001/services/trackbacks/432827.html</trackback:ping><description><![CDATA[表单里面先对某一个控件有效性验证(如手机号码，当手机号码输入正确，才发送验证码，最后才是对表单验证)
<div>
<p style="margin: 0px; font-size: 11px; line-height: normal; font-family: Monaco; color: #3933ff;"><span style="color: #009193">&lt;</span><span style="color: #4e9192">input</span><span style="color: #000000"> </span><span style="color: #932192">type</span><span style="color: #000000">=</span>"text"<span style="color: #000000"> </span><span style="color: #932192">id</span><span style="color: #000000">=</span>"mobile"<span style="color: #000000"> </span><span style="color: #932192">name</span><span style="color: #000000">=</span>"mobile"&nbsp;<span style="color: #932192;">placeholder</span><span style="color: #000000;">=</span>"请输入您的手机号码"&nbsp;<span style="color: #932192;">class</span><span style="color: #000000;">=</span>"easyui-validatebox form-control"&nbsp;<span style="color: #932192;">data-options</span><span style="color: #000000;">=</span>"required:true,validType:'mobile'"<span style="color: #000000;"> </span><span style="color: #009193;">/&gt;</span></p>
<p style="margin: 0px; font-size: 11px; line-height: normal; font-family: Monaco; color: #3933ff;"><span style="color: #009193;">validateType自己扩展规则</span></p>
<div>对单个输入框的验证为：<span style="font-family: Monaco; font-size: 11px;">$(</span><span style="color: #3933ff; font-family: Monaco; font-size: 11px;">"#mobile"</span><span style="font-family: Monaco; font-size: 11px;">).validatebox(</span><span style="color: #3933ff; font-family: Monaco; font-size: 11px;">'isValid'</span><span style="font-family: Monaco; font-size: 11px;">) 通过返回true</span></div>
</div><img src ="http://www.blogjava.net/lyyb2001/aggbug/432827.html" width = "1" height = "1" /><br><br><div align=right><a style="text-decoration:none;" href="http://www.blogjava.net/lyyb2001/" target="_blank">skycity</a> 2017-09-19 15:59 <a href="http://www.blogjava.net/lyyb2001/archive/2017/09/19/432827.html#Feedback" target="_blank" style="text-decoration:none;">发表评论</a></div>]]></description></item><item><title>利用lumbda将enum转成map</title><link>http://www.blogjava.net/lyyb2001/archive/2017/07/11/432660.html</link><dc:creator>skycity</dc:creator><author>skycity</author><pubDate>Tue, 11 Jul 2017 03:40:00 GMT</pubDate><guid>http://www.blogjava.net/lyyb2001/archive/2017/07/11/432660.html</guid><wfw:comment>http://www.blogjava.net/lyyb2001/comments/432660.html</wfw:comment><comments>http://www.blogjava.net/lyyb2001/archive/2017/07/11/432660.html#Feedback</comments><slash:comments>0</slash:comments><wfw:commentRss>http://www.blogjava.net/lyyb2001/comments/commentRss/432660.html</wfw:commentRss><trackback:ping>http://www.blogjava.net/lyyb2001/services/trackbacks/432660.html</trackback:ping><description><![CDATA[<div>&nbsp; &nbsp; public enum Section {</div><div><span style="white-space:pre">	</span>KITTING(1),</div><div><span style="white-space:pre">	</span>LABELKITTING(2),</div><div><span style="white-space:pre">	</span>PACKING(3);<br /><br /><div>private final int code;<br /><br /><div>private Section(int code)</div><div><span style="white-space:pre">	</span>{</div><div><span style="white-space:pre">		</span>this.code=code;</div><div><span style="white-space:pre">	</span>}</div><div><span style="white-space:pre">	</span></div><div><span style="white-space:pre">	</span>public int getCode()</div><div><span style="white-space:pre">	</span>{</div><div><span style="white-space:pre">		</span>return this.code;</div><div><span style="white-space:pre">	</span>}</div></div>}<br /><br /><div>Map&lt;Integer,Section&gt; MAP=Arrays.stream(Section.values()).collect(Collectors.toMap(s-&gt;s.code, section-&gt;section));</div></div><img src ="http://www.blogjava.net/lyyb2001/aggbug/432660.html" width = "1" height = "1" /><br><br><div align=right><a style="text-decoration:none;" href="http://www.blogjava.net/lyyb2001/" target="_blank">skycity</a> 2017-07-11 11:40 <a href="http://www.blogjava.net/lyyb2001/archive/2017/07/11/432660.html#Feedback" target="_blank" style="text-decoration:none;">发表评论</a></div>]]></description></item><item><title>java 8 stream根据对象进行比较，或者最大的那条记录的值 </title><link>http://www.blogjava.net/lyyb2001/archive/2017/07/06/432648.html</link><dc:creator>skycity</dc:creator><author>skycity</author><pubDate>Thu, 06 Jul 2017 07:43:00 GMT</pubDate><guid>http://www.blogjava.net/lyyb2001/archive/2017/07/06/432648.html</guid><wfw:comment>http://www.blogjava.net/lyyb2001/comments/432648.html</wfw:comment><comments>http://www.blogjava.net/lyyb2001/archive/2017/07/06/432648.html#Feedback</comments><slash:comments>0</slash:comments><wfw:commentRss>http://www.blogjava.net/lyyb2001/comments/commentRss/432648.html</wfw:commentRss><trackback:ping>http://www.blogjava.net/lyyb2001/services/trackbacks/432648.html</trackback:ping><description><![CDATA[<span style="white-space:pre">	</span>Optional&lt;MaterialPaneModel&gt; maxMaterial = list.stream().max(Comparator.comparingInt(MaterialPaneModel::getMaterialQty));<img src ="http://www.blogjava.net/lyyb2001/aggbug/432648.html" width = "1" height = "1" /><br><br><div align=right><a style="text-decoration:none;" href="http://www.blogjava.net/lyyb2001/" target="_blank">skycity</a> 2017-07-06 15:43 <a href="http://www.blogjava.net/lyyb2001/archive/2017/07/06/432648.html#Feedback" target="_blank" style="text-decoration:none;">发表评论</a></div>]]></description></item><item><title>cxf 客服端调用设置超时</title><link>http://www.blogjava.net/lyyb2001/archive/2016/12/08/432062.html</link><dc:creator>skycity</dc:creator><author>skycity</author><pubDate>Thu, 08 Dec 2016 06:19:00 GMT</pubDate><guid>http://www.blogjava.net/lyyb2001/archive/2016/12/08/432062.html</guid><wfw:comment>http://www.blogjava.net/lyyb2001/comments/432062.html</wfw:comment><comments>http://www.blogjava.net/lyyb2001/archive/2016/12/08/432062.html#Feedback</comments><slash:comments>0</slash:comments><wfw:commentRss>http://www.blogjava.net/lyyb2001/comments/commentRss/432062.html</wfw:commentRss><trackback:ping>http://www.blogjava.net/lyyb2001/services/trackbacks/432062.html</trackback:ping><description><![CDATA[<p>try{</p> <p>			JaxWsProxyFactoryBean factoryBean = new JaxWsProxyFactoryBean();</p> <p>			factoryBean.getInInterceptors().add(new LoggingInInterceptor());</p> <p>			factoryBean.getOutInterceptors().add(new LoggingOutInterceptor());</p> <p>			factoryBean.setServiceClass(AutoPackServiceIntf.class);</p> <p>			factoryBean.setAddress("http://10.241.0.105:17000/TEST");</p> <p>			AutoPackServiceIntf factory = (AutoPackServiceIntf) factoryBean.create();</p> <p>			Client client = ClientProxy.getClient(factory);</p> <p>			HTTPConduit conduit = (HTTPConduit) client.getConduit();</p> <p>			HTTPClientPolicy policy = new HTTPClientPolicy();</p> <p>			policy.setConnectionTimeout(30000); 	//连接超时时间</p> <p>			policy.setReceiveTimeout(120000);	//请求超时时间.</p> <p>			conduit.setClient(policy);</p> <p>			System.out.println(factory.getFirstUnitCramp("1"));</p> <p>		}catch(WebServiceException ex){</p> <p>			long l2 = System.currentTimeMillis();</p> <p>			System.out.println((l2-l1)+"ms");</p> <p>			System.out.println("连接异常");</p> <p>		}</p><img src ="http://www.blogjava.net/lyyb2001/aggbug/432062.html" width = "1" height = "1" /><br><br><div align=right><a style="text-decoration:none;" href="http://www.blogjava.net/lyyb2001/" target="_blank">skycity</a> 2016-12-08 14:19 <a href="http://www.blogjava.net/lyyb2001/archive/2016/12/08/432062.html#Feedback" target="_blank" style="text-decoration:none;">发表评论</a></div>]]></description></item><item><title>JBOSS 如何读取properties文件</title><link>http://www.blogjava.net/lyyb2001/archive/2016/11/03/431949.html</link><dc:creator>skycity</dc:creator><author>skycity</author><pubDate>Thu, 03 Nov 2016 10:17:00 GMT</pubDate><guid>http://www.blogjava.net/lyyb2001/archive/2016/11/03/431949.html</guid><wfw:comment>http://www.blogjava.net/lyyb2001/comments/431949.html</wfw:comment><comments>http://www.blogjava.net/lyyb2001/archive/2016/11/03/431949.html#Feedback</comments><slash:comments>0</slash:comments><wfw:commentRss>http://www.blogjava.net/lyyb2001/comments/commentRss/431949.html</wfw:commentRss><trackback:ping>http://www.blogjava.net/lyyb2001/services/trackbacks/431949.html</trackback:ping><description><![CDATA[<p>通过Application<br /></p><p>ApplicationContext classPathXmlApplicationContext = new ClassPathXmlApplicationContext();</p> <p>&nbsp; &nbsp; &nbsp;classPath = classPathXmlApplicationContext.getResource("classpath:config.properties").getFile().getPath();</p> <p>&nbsp; &nbsp; &nbsp; &nbsp; 	if(classPath.indexOf("WEB-INF")&gt;0){</p> <p>&nbsp; &nbsp; &nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp; 		classPath = classPath.substring(0,classPath.indexOf("WEB-INF")+7)+"/classes/"+xmlFile;</p> <p>&nbsp; &nbsp; &nbsp; &nbsp; 	}<br /><br /></p><p>&nbsp;</p><img src ="http://www.blogjava.net/lyyb2001/aggbug/431949.html" width = "1" height = "1" /><br><br><div align=right><a style="text-decoration:none;" href="http://www.blogjava.net/lyyb2001/" target="_blank">skycity</a> 2016-11-03 18:17 <a href="http://www.blogjava.net/lyyb2001/archive/2016/11/03/431949.html#Feedback" target="_blank" style="text-decoration:none;">发表评论</a></div>]]></description></item><item><title>java8 stream groupingby多个条件的问题</title><link>http://www.blogjava.net/lyyb2001/archive/2016/03/22/429766.html</link><dc:creator>skycity</dc:creator><author>skycity</author><pubDate>Tue, 22 Mar 2016 08:14:00 GMT</pubDate><guid>http://www.blogjava.net/lyyb2001/archive/2016/03/22/429766.html</guid><wfw:comment>http://www.blogjava.net/lyyb2001/comments/429766.html</wfw:comment><comments>http://www.blogjava.net/lyyb2001/archive/2016/03/22/429766.html#Feedback</comments><slash:comments>0</slash:comments><wfw:commentRss>http://www.blogjava.net/lyyb2001/comments/commentRss/429766.html</wfw:commentRss><trackback:ping>http://www.blogjava.net/lyyb2001/services/trackbacks/429766.html</trackback:ping><description><![CDATA[@import url(http://www.blogjava.net/CuteSoft_Client/CuteEditor/Load.ashx?type=style&file=SyntaxHighlighter.css);@import url(/css/cuteeditor.css);
@import url(http://www.blogjava.net/CuteSoft_Client/CuteEditor/Load.ashx?type=style&file=SyntaxHighlighter.css);@import url(/css/cuteeditor.css);
@import url(http://www.blogjava.net/CuteSoft_Client/CuteEditor/Load.ashx?type=style&file=SyntaxHighlighter.css);@import url(/css/cuteeditor.css);
@import url(http://www.blogjava.net/CuteSoft_Client/CuteEditor/Load.ashx?type=style&file=SyntaxHighlighter.css);@import url(/css/cuteeditor.css);
@import url(http://www.blogjava.net/CuteSoft_Client/CuteEditor/Load.ashx?type=style&file=SyntaxHighlighter.css);@import url(/css/cuteeditor.css);
<p style="margin: 0px; font-size: 11px; line-height: normal; font-family: Monaco;">Map&lt;Integer,Map&lt;String,List&lt;DocLotDetail&gt;&gt;&gt; <span style="color: #7e504f">amp</span><span style="font-family: verdana, 'courier new'; font-size: 14px;">&nbsp; &nbsp;&nbsp;</span><span style="font-family: verdana, 'courier new'; font-size: 14px;">&nbsp; &nbsp;&nbsp;</span><span style="font-family: verdana, 'courier new'; font-size: 14px;">&nbsp; &nbsp;&nbsp;</span><span style="font-family: verdana, 'courier new'; font-size: 14px;">&nbsp; &nbsp;&nbsp;</span><span style="font-family: verdana, 'courier new'; font-size: 14px;">&nbsp; &nbsp;&nbsp;</span><span style="font-family: verdana, 'courier new'; font-size: 14px;">&nbsp; &nbsp;&nbsp;</span><span style="font-family: verdana, 'courier new'; font-size: 14px;">&nbsp; &nbsp;&nbsp;</span>=&nbsp;<span style="color: #7e504f;">docLotDetailLists</span>.parallelStream().collect(Collectors.groupingBy(DocLotDetail::getGroupOrder,Collectors.groupingBy(DocLotDetail::getBaseValueName)));</p>
<p style="margin: 0px; font-size: 11px; line-height: normal; font-family: Monaco;"><br />
</p>
<p style="margin: 0px; font-size: 11px; line-height: normal; font-family: Monaco;"><br />
</p>
<p style="margin: 0px; font-size: 11px; line-height: normal; font-family: Monaco;"><br />
</p>
<p style="margin: 0px; font-size: 11px; line-height: normal; font-family: Monaco;"><br />
</p>
<p style="margin: 0px; font-size: 11px; line-height: normal; font-family: Monaco;"><span style="color: #7e504f">amp</span>.forEach((<span style="color: #7e504f">key</span>,<span style="color: #7e504f">value</span>)-&gt;{</p>
<p style="margin: 0px; font-size: 11px; line-height: normal; font-family: Monaco;"><span class="Apple-tab-span" style="white-space:pre"> </span><span style="font-family: verdana, 'courier new'; font-size: 14px;">&nbsp; &nbsp;&nbsp;</span><span style="font-family: verdana, 'courier new'; font-size: 14px;">&nbsp; &nbsp;&nbsp;</span>System.<span style="color: #0326cc;">out</span>.println(<span style="color: #7e504f;">key</span>);</p>
<p style="margin: 0px; font-size: 11px; line-height: normal; font-family: Monaco;"><span style="font-family: verdana, 'courier new'; font-size: 14px;">&nbsp; &nbsp;&nbsp;</span><span style="font-family: verdana, 'courier new'; font-size: 14px;">&nbsp; &nbsp;&nbsp;</span><span class="Apple-tab-span" style="white-space: pre;"> </span><span style="color: #7e504f;">value</span>.forEach((<span style="color: #7e504f;">key2</span>,<span style="color: #7e504f;">value2</span>)-&gt;{</p>
<p style="margin: 0px; font-size: 11px; line-height: normal; font-family: Monaco;"><span class="Apple-tab-span" style="white-space:pre"> </span><span style="font-family: verdana, 'courier new'; font-size: 14px;">&nbsp; &nbsp;&nbsp;</span><span style="font-family: verdana, 'courier new'; font-size: 14px;">&nbsp; &nbsp;&nbsp;</span><span style="font-family: verdana, 'courier new'; font-size: 14px;">&nbsp; &nbsp;&nbsp;</span>System.<span style="color: #0326cc;">out</span>.println(<span style="color: #7e504f;">key2</span>);</p>
<p style="margin: 0px; font-size: 11px; line-height: normal; font-family: Monaco;"><span class="Apple-tab-span" style="white-space:pre"> </span><span style="font-family: verdana, 'courier new'; font-size: 14px;">&nbsp; &nbsp;&nbsp;</span><span style="font-family: verdana, 'courier new'; font-size: 14px;">&nbsp; &nbsp;&nbsp;</span>});</p>
<p style="margin: 0px; font-size: 11px; line-height: normal; font-family: Monaco;">
</p>
<p style="margin: 0px; font-size: 11px; line-height: normal; font-family: Monaco;"><span class="Apple-tab-span" style="white-space:pre"> </span>});</p>
<p style="margin: 0px; font-size: 11px; line-height: normal; font-family: Monaco;">最终返回的结果</p>
<p style="margin: 0px; font-size: 11px; line-height: normal; font-family: Monaco;">2</p>
<p style="margin: 0px; font-size: 11px; line-height: normal; font-family: Monaco;">随机光盘</p>
<p style="margin: 0px; font-size: 11px; line-height: normal; font-family: Monaco;">3</p>
<p style="margin: 0px; font-size: 11px; line-height: normal; font-family: Monaco;">资料袋附件</p>
<p style="margin: 0px; font-size: 11px; line-height: normal; font-family: Monaco;">4</p>
<p style="margin: 0px; font-size: 11px; line-height: normal; font-family: Monaco;">资料盒附件</p>
<p style="margin: 0px; font-size: 11px; line-height: normal; font-family: Monaco;">5</p>
<p style="margin: 0px; font-size: 11px; line-height: normal; font-family: Monaco;">包装辅料</p>
<p style="margin: 0px; font-size: 11px; line-height: normal; font-family: Monaco;">8</p>
<p style="margin: 0px; font-size: 11px; line-height: normal; font-family: Monaco;">
</p>
<p style="margin: 0px; font-size: 11px; line-height: normal; font-family: Monaco;">前工序物料</p>
<p style="margin: 0px; font-size: 11px; line-height: normal; font-family: Monaco;"><br />
</p>
<p style="margin: 0px; font-size: 11px; line-height: normal; font-family: Monaco;"><br />
</p>
<p style="margin: 0px; font-size: 11px; line-height: normal; font-family: Monaco;"><br />
</p>
<p style="margin: 0px; font-size: 11px; line-height: normal; font-family: Monaco;"><br />
</p>
<p style="margin: 0px; font-size: 11px; line-height: normal; font-family: Monaco;"><br />
</p>
@import url(http://www.blogjava.net/CuteSoft_Client/CuteEditor/Load.ashx?type=style&file=SyntaxHighlighter.css);@import url(/css/cuteeditor.css);<img src ="http://www.blogjava.net/lyyb2001/aggbug/429766.html" width = "1" height = "1" /><br><br><div align=right><a style="text-decoration:none;" href="http://www.blogjava.net/lyyb2001/" target="_blank">skycity</a> 2016-03-22 16:14 <a href="http://www.blogjava.net/lyyb2001/archive/2016/03/22/429766.html#Feedback" target="_blank" style="text-decoration:none;">发表评论</a></div>]]></description></item><item><title>Caused by: org.apache.cxf.BusException: No binding factory for namespace http://schemas.xmlsoap.org/soap/ registered.</title><link>http://www.blogjava.net/lyyb2001/archive/2016/03/04/429535.html</link><dc:creator>skycity</dc:creator><author>skycity</author><pubDate>Fri, 04 Mar 2016 07:02:00 GMT</pubDate><guid>http://www.blogjava.net/lyyb2001/archive/2016/03/04/429535.html</guid><wfw:comment>http://www.blogjava.net/lyyb2001/comments/429535.html</wfw:comment><comments>http://www.blogjava.net/lyyb2001/archive/2016/03/04/429535.html#Feedback</comments><slash:comments>0</slash:comments><wfw:commentRss>http://www.blogjava.net/lyyb2001/comments/commentRss/429535.html</wfw:commentRss><trackback:ping>http://www.blogjava.net/lyyb2001/services/trackbacks/429535.html</trackback:ping><description><![CDATA[<p style="margin: 0px; font-size: 11px; line-height: normal; font-family: Menlo;">cxf webservice客户端程序在eclipse里面运行的好好的，但是一旦用mvn&nbsp;assembly:assembly将依赖和主代码打成一个可运行的jar时，调用就会出现如下错误：</p>
<p style="margin: 0px; font-size: 11px; line-height: normal; font-family: Menlo;"><br />
</p>
<p style="margin: 0px; font-size: 11px; line-height: normal; font-family: Menlo;">Exception in thread "main" org.apache.cxf.service.factory.ServiceConstructionException: Could not resolve a binding for null</p>
<p style="margin: 0px; font-size: 11px; line-height: normal; font-family: Menlo;"><span class="Apple-tab-span" style="white-space:pre">	</span>at org.apache.cxf.frontend.AbstractWSDLBasedEndpointFactory.createBindingInfo(AbstractWSDLBasedEndpointFactory.java:352)</p>
<p style="margin: 0px; font-size: 11px; line-height: normal; font-family: Menlo;"><span class="Apple-tab-span" style="white-space:pre">	</span>at org.apache.cxf.frontend.AbstractWSDLBasedEndpointFactory.createEndpointInfo(AbstractWSDLBasedEndpointFactory.java:259)</p>
<p style="margin: 0px; font-size: 11px; line-height: normal; font-family: Menlo;"><span class="Apple-tab-span" style="white-space:pre">	</span>at org.apache.cxf.frontend.AbstractWSDLBasedEndpointFactory.createEndpoint(AbstractWSDLBasedEndpointFactory.java:144)</p>
<p style="margin: 0px; font-size: 11px; line-height: normal; font-family: Menlo;"><span class="Apple-tab-span" style="white-space:pre">	</span>at org.apache.cxf.frontend.ClientFactoryBean.create(ClientFactoryBean.java:91)</p>
<p style="margin: 0px; font-size: 11px; line-height: normal; font-family: Menlo;"><span class="Apple-tab-span" style="white-space:pre">	</span>at org.apache.cxf.frontend.ClientProxyFactoryBean.create(ClientProxyFactoryBean.java:157)</p>
<p style="margin: 0px; font-size: 11px; line-height: normal; font-family: Menlo;"><span class="Apple-tab-span" style="white-space:pre">	</span>at org.apache.cxf.jaxws.JaxWsProxyFactoryBean.create(JaxWsProxyFactoryBean.java:142)</p>
<p style="margin: 0px; font-size: 11px; line-height: normal; font-family: Menlo;"><span class="Apple-tab-span" style="white-space:pre">	</span>at com.nabf.start.NABFClient.main(NABFClient.java:30)</p>
<p style="margin: 0px; font-size: 11px; line-height: normal; font-family: Menlo;">Caused by: org.apache.cxf.BusException: No binding factory for namespace http://schemas.xmlsoap.org/soap/ registered.</p>
<p style="margin: 0px; font-size: 11px; line-height: normal; font-family: Menlo;"><span class="Apple-tab-span" style="white-space:pre">	</span>at org.apache.cxf.bus.managers.BindingFactoryManagerImpl.getBindingFactory(BindingFactoryManagerImpl.java:93)</p>
<p style="margin: 0px; font-size: 11px; line-height: normal; font-family: Menlo;"><span class="Apple-tab-span" style="white-space:pre">	</span>at org.apache.cxf.frontend.AbstractWSDLBasedEndpointFactory.createBindingInfo(AbstractWSDLBasedEndpointFactory.java:339)</p>
<p style="margin: 0px; font-size: 11px; line-height: normal; font-family: Menlo;"><span class="Apple-tab-span" style="white-space:pre">	</span>... 6 more</p>
<div>而用mV clean package dependency:copy-dependencies -DoutputDirectory=target/lib启动的时候加载lib包下所有的文件也不会出现错误</div>
<div><br />
</div>
<div>解决办法：在pom.xml的build中添加如下，然后执行mV clean package，打出来的包就含有依赖包，且问题解决。原因？</div>
<div>
<p style="margin: 0px; font-size: 11px; line-height: normal; font-family: Monaco; color: #4f76cb;"><span style="font-family: verdana, 'courier new'; font-size: 14px;">&nbsp; &nbsp;&nbsp;</span><span style="font-family: verdana, 'courier new'; font-size: 14px;">&nbsp; &nbsp;&nbsp;</span><span style="font-family: verdana, 'courier new'; font-size: 14px;">&nbsp; &nbsp;&nbsp;</span><span style="font-family: verdana, 'courier new'; font-size: 14px;">&nbsp; &nbsp;&nbsp;</span><span style="font-family: verdana, 'courier new'; font-size: 14px;">&nbsp; &nbsp;&nbsp;</span><span style="font-family: verdana, 'courier new'; font-size: 14px;">&nbsp; &nbsp;&nbsp;</span><span style="font-family: verdana, 'courier new'; font-size: 14px;">&nbsp; &nbsp;&nbsp;</span><span style="text-decoration: underline;">&lt;plugin&gt;</span></p>
<p style="margin: 0px; font-size: 11px; line-height: normal; font-family: Monaco; color: #4f76cb;"><span class="Apple-tab-span" style="white-space:pre">				</span>&lt;groupId&gt;org.apache.maven.plugins&lt;/groupId&gt;</p>
<p style="margin: 0px; font-size: 11px; line-height: normal; font-family: Monaco; color: #4f76cb;"><span class="Apple-tab-span" style="white-space:pre">				</span>&lt;artifactId&gt;<span style="text-decoration: underline">maven</span>-shade-<span style="text-decoration: underline">plugin</span>&lt;/artifactId&gt;</p>
<p style="margin: 0px; font-size: 11px; line-height: normal; font-family: Monaco; color: #4f76cb;"><span class="Apple-tab-span" style="white-space:pre">				</span>&lt;version&gt;1.6&lt;/version&gt;</p>
<p style="margin: 0px; font-size: 11px; line-height: normal; font-family: Monaco; color: #4f76cb;"><span class="Apple-tab-span" style="white-space:pre">				</span>&lt;configuration&gt;</p>
<p style="margin: 0px; font-size: 11px; line-height: normal; font-family: Monaco; color: #4f76cb;"><span class="Apple-tab-span" style="white-space:pre">					</span>&lt;archive&gt;</p>
<p style="margin: 0px; font-size: 11px; line-height: normal; font-family: Monaco; color: #4f76cb;"><span class="Apple-tab-span" style="white-space:pre">						</span>&lt;manifest&gt;</p>
<p style="margin: 0px; font-size: 11px; line-height: normal; font-family: Monaco; color: #4f76cb;"><span class="Apple-tab-span" style="white-space:pre">							</span>&lt;addClasspath&gt;true&lt;/addClasspath&gt;</p>
<p style="margin: 0px; font-size: 11px; line-height: normal; font-family: Monaco; color: #4f76cb;"><span class="Apple-tab-span" style="white-space:pre">							</span>&lt;mainClass&gt;com.nabf.start.NABFClient&lt;/mainClass&gt;</p>
<p style="margin: 0px; font-size: 11px; line-height: normal; font-family: Monaco; color: #4f76cb;"><span class="Apple-tab-span" style="white-space:pre">						</span>&lt;/manifest&gt;</p>
<p style="margin: 0px; font-size: 11px; line-height: normal; font-family: Monaco; color: #4f76cb;"><span class="Apple-tab-span" style="white-space:pre">					</span>&lt;/archive&gt;</p>
<p style="margin: 0px; font-size: 11px; line-height: normal; font-family: Monaco; color: #4f76cb;"><span class="Apple-tab-span" style="white-space:pre">				</span>&lt;/configuration&gt;</p>
<p style="margin: 0px; font-size: 11px; line-height: normal; font-family: Monaco; color: #4f76cb;"><span class="Apple-tab-span" style="white-space:pre">				</span>&lt;executions&gt;</p>
<p style="margin: 0px; font-size: 11px; line-height: normal; font-family: Monaco; color: #4f76cb;"><span class="Apple-tab-span" style="white-space:pre">					</span>&lt;execution&gt;</p>
<p style="margin: 0px; font-size: 11px; line-height: normal; font-family: Monaco; color: #4f76cb;"><span class="Apple-tab-span" style="white-space:pre">						</span>&lt;phase&gt;package&lt;/phase&gt;</p>
<p style="margin: 0px; font-size: 11px; line-height: normal; font-family: Monaco; color: #4f76cb;"><span class="Apple-tab-span" style="white-space:pre">						</span>&lt;goals&gt;</p>
<p style="margin: 0px; font-size: 11px; line-height: normal; font-family: Monaco; color: #4f76cb;"><span class="Apple-tab-span" style="white-space:pre">							</span>&lt;goal&gt;shade&lt;/goal&gt;</p>
<p style="margin: 0px; font-size: 11px; line-height: normal; font-family: Monaco; color: #4f76cb;"><span class="Apple-tab-span" style="white-space:pre">						</span>&lt;/goals&gt;</p>
<p style="margin: 0px; font-size: 11px; line-height: normal; font-family: Monaco; color: #4f76cb;"><span class="Apple-tab-span" style="white-space:pre">						</span>&lt;configuration&gt;</p>
<p style="margin: 0px; font-size: 11px; line-height: normal; font-family: Monaco; color: #4f76cb;"><span class="Apple-tab-span" style="white-space:pre">							</span>&lt;transformers&gt;</p>
<p style="margin: 0px; font-size: 11px; line-height: normal; font-family: Monaco; color: #4f76cb;"><span class="Apple-tab-span" style="white-space:pre">								</span>&lt;transformer</p>
<p style="margin: 0px; font-size: 11px; line-height: normal; font-family: Monaco; color: #4f76cb;"><span class="Apple-tab-span" style="white-space:pre">									</span>implementation="org.apache.maven.plugins.shade.resource.AppendingTransformer"&gt;</p>
<p style="margin: 0px; font-size: 11px; line-height: normal; font-family: Monaco; color: #4f76cb;"><span class="Apple-tab-span" style="white-space:pre">									</span>&lt;resource&gt;META-INF/<span style="text-decoration: underline">cxf</span>/bus-extensions.txt&lt;/resource&gt;</p>
<p style="margin: 0px; font-size: 11px; line-height: normal; font-family: Monaco; color: #4f76cb;"><span class="Apple-tab-span" style="white-space:pre">								</span>&lt;/transformer&gt;</p>
<p style="margin: 0px; font-size: 11px; line-height: normal; font-family: Monaco; color: #4f76cb;"><span class="Apple-tab-span" style="white-space:pre">							</span>&lt;/transformers&gt;</p>
<p style="margin: 0px; font-size: 11px; line-height: normal; font-family: Monaco; color: #4f76cb;"><span class="Apple-tab-span" style="white-space:pre">						</span>&lt;/configuration&gt;</p>
<p style="margin: 0px; font-size: 11px; line-height: normal; font-family: Monaco; color: #4f76cb;"><span class="Apple-tab-span" style="white-space:pre">					</span>&lt;/execution&gt;</p>
<p style="margin: 0px; font-size: 11px; line-height: normal; font-family: Monaco; color: #4f76cb;"><span class="Apple-tab-span" style="white-space:pre">				</span>&lt;/executions&gt;</p>
<p style="margin: 0px; font-size: 11px; line-height: normal; font-family: Monaco; color: #4f76cb;"><span class="Apple-tab-span" style="white-space:pre">			</span><span style="text-decoration: underline">&lt;/plugin&gt;</span>&nbsp;</p>
</div>
<div><br />
</div>
<div><br />
</div>
<div><br />
</div>
@import url(http://www.blogjava.net/CuteSoft_Client/CuteEditor/Load.ashx?type=style&file=SyntaxHighlighter.css);@import url(/css/cuteeditor.css);<img src ="http://www.blogjava.net/lyyb2001/aggbug/429535.html" width = "1" height = "1" /><br><br><div align=right><a style="text-decoration:none;" href="http://www.blogjava.net/lyyb2001/" target="_blank">skycity</a> 2016-03-04 15:02 <a href="http://www.blogjava.net/lyyb2001/archive/2016/03/04/429535.html#Feedback" target="_blank" style="text-decoration:none;">发表评论</a></div>]]></description></item><item><title>properties文件替换</title><link>http://www.blogjava.net/lyyb2001/archive/2015/06/11/425628.html</link><dc:creator>skycity</dc:creator><author>skycity</author><pubDate>Thu, 11 Jun 2015 08:10:00 GMT</pubDate><guid>http://www.blogjava.net/lyyb2001/archive/2015/06/11/425628.html</guid><wfw:comment>http://www.blogjava.net/lyyb2001/comments/425628.html</wfw:comment><comments>http://www.blogjava.net/lyyb2001/archive/2015/06/11/425628.html#Feedback</comments><slash:comments>0</slash:comments><wfw:commentRss>http://www.blogjava.net/lyyb2001/comments/commentRss/425628.html</wfw:commentRss><trackback:ping>http://www.blogjava.net/lyyb2001/services/trackbacks/425628.html</trackback:ping><description><![CDATA[@import url(http://www.blogjava.net/CuteSoft_Client/CuteEditor/Load.ashx?type=style&file=SyntaxHighlighter.css);@import url(/css/cuteeditor.css);
<p style="margin: 0px; font-size: 11px; line-height: normal; font-family: Monaco;">MessageFormat.format(str,str1,str2,str3)</p>
<p style="margin: 0px; font-size: 11px; line-height: normal; font-family: Monaco;">用于替换str中{0},{1},{2}这样的结构</p>
<p style="margin: 0px; font-size: 11px; line-height: normal; font-family: Monaco;">String.format(str,str1,str2,str3)</p>
<p style="margin: 0px; font-size: 11px; line-height: normal; font-family: Monaco;">用于匹配str中%s的结构</p><img src ="http://www.blogjava.net/lyyb2001/aggbug/425628.html" width = "1" height = "1" /><br><br><div align=right><a style="text-decoration:none;" href="http://www.blogjava.net/lyyb2001/" target="_blank">skycity</a> 2015-06-11 16:10 <a href="http://www.blogjava.net/lyyb2001/archive/2015/06/11/425628.html#Feedback" target="_blank" style="text-decoration:none;">发表评论</a></div>]]></description></item><item><title>登陆用户名的加密与解密</title><link>http://www.blogjava.net/lyyb2001/archive/2015/03/27/423881.html</link><dc:creator>skycity</dc:creator><author>skycity</author><pubDate>Fri, 27 Mar 2015 02:50:00 GMT</pubDate><guid>http://www.blogjava.net/lyyb2001/archive/2015/03/27/423881.html</guid><wfw:comment>http://www.blogjava.net/lyyb2001/comments/423881.html</wfw:comment><comments>http://www.blogjava.net/lyyb2001/archive/2015/03/27/423881.html#Feedback</comments><slash:comments>0</slash:comments><wfw:commentRss>http://www.blogjava.net/lyyb2001/comments/commentRss/423881.html</wfw:commentRss><trackback:ping>http://www.blogjava.net/lyyb2001/services/trackbacks/423881.html</trackback:ping><description><![CDATA[package com.skycity.framework.utility;<br />
<div>import javax.crypto.Cipher;</div>
<div>import javax.crypto.KeyGenerator;</div>
<div>import javax.crypto.SecretKey;</div>
<div>import javax.crypto.spec.SecretKeySpec;</div>
<div><br />
</div>
<div>import sun.misc.BASE64Decoder;</div>
<div>import sun.misc.BASE64Encoder;</div>
<div><br />
</div>
<div>import com.skycity.framework.Constant;</div>
<div><br />
</div>
<div>public class EncryptUtil {</div>
<div>&nbsp; &nbsp; // 加密字符串</div>
<div>&nbsp; &nbsp; public static String encryptMode(String keybyte, String src) {</div>
<div>&nbsp; &nbsp; &nbsp; &nbsp; try { // 生成密钥</div>
<div>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; SecretKey deskey = new SecretKeySpec(new BASE64Decoder().decodeBuffer(keybyte), Constant.ALGORITHM); // 加密</div>
<div>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; Cipher c1 = Cipher.getInstance(Constant.ALGORITHM);</div>
<div>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; c1.init(Cipher.ENCRYPT_MODE, deskey);</div>
<div>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; byte[] result = c1.doFinal(src.getBytes());</div>
<div>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; return new BASE64Encoder().encode(result);</div>
<div>&nbsp; &nbsp; &nbsp; &nbsp; } catch (java.security.NoSuchAlgorithmException e1) {</div>
<div>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; e1.printStackTrace();</div>
<div>&nbsp; &nbsp; &nbsp; &nbsp; } catch (javax.crypto.NoSuchPaddingException e2) {</div>
<div>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; e2.printStackTrace();</div>
<div>&nbsp; &nbsp; &nbsp; &nbsp; } catch (java.lang.Exception e3) {</div>
<div>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; e3.printStackTrace();</div>
<div>&nbsp; &nbsp; &nbsp; &nbsp; }</div>
<div>&nbsp; &nbsp; &nbsp; &nbsp; return null;</div>
<div>&nbsp; &nbsp; }</div>
<div>&nbsp;</div>
<div>&nbsp; &nbsp; // 解密字符串</div>
<div>&nbsp; &nbsp; public static String decryptMode(String keybyte, String encryStr) {</div>
<div>&nbsp; &nbsp; &nbsp; &nbsp; try { // 生成密钥</div>
<div>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; SecretKey deskey = new SecretKeySpec(new BASE64Decoder().decodeBuffer(keybyte), Constant.ALGORITHM); // 解密</div>
<div>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; Cipher c1 = Cipher.getInstance(Constant.ALGORITHM);</div>
<div>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; c1.init(Cipher.DECRYPT_MODE, deskey);</div>
<div>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; byte[] result = c1.doFinal(new BASE64Decoder().decodeBuffer(encryStr));</div>
<div>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; return new String(result);</div>
<div>&nbsp; &nbsp; &nbsp; &nbsp; } catch (java.security.NoSuchAlgorithmException e1) {</div>
<div>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; e1.printStackTrace();</div>
<div>&nbsp; &nbsp; &nbsp; &nbsp; } catch (javax.crypto.NoSuchPaddingException e2) {</div>
<div>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; e2.printStackTrace();</div>
<div>&nbsp; &nbsp; &nbsp; &nbsp; } catch (java.lang.Exception e3) {</div>
<div>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; e3.printStackTrace();</div>
<div>&nbsp; &nbsp; &nbsp; &nbsp; }</div>
<div>&nbsp; &nbsp; &nbsp; &nbsp; return null;</div>
<div>&nbsp; &nbsp; }</div>
<div>&nbsp; &nbsp; //创建一个密钥</div>
<div>&nbsp; &nbsp; public static byte[] createSecretKey() {</div>
<div><span class="Apple-tab-span" style="white-space:pre">		</span>KeyGenerator keygen = null;</div>
<div><span class="Apple-tab-span" style="white-space:pre">		</span>try {</div>
<div><span class="Apple-tab-span" style="white-space:pre">			</span>keygen = KeyGenerator.getInstance(Constant.ALGORITHM);</div>
<div><span class="Apple-tab-span" style="white-space:pre">			</span>SecretKey deskey = keygen.generateKey();</div>
<div><span class="Apple-tab-span" style="white-space:pre">			</span>return deskey.getEncoded();</div>
<div><span class="Apple-tab-span" style="white-space:pre">		</span>} catch (Exception e) {</div>
<div><span class="Apple-tab-span" style="white-space:pre">			</span>LogUtil.error("NoSuchAlgorithmException!");</div>
<div><span class="Apple-tab-span" style="white-space:pre">		</span>}</div>
<div><span class="Apple-tab-span" style="white-space:pre">		</span>return null;</div>
<div><span class="Apple-tab-span" style="white-space:pre">	</span>}</div>
<div>&nbsp; &nbsp;&nbsp;</div>
<div>&nbsp; &nbsp; public static void main(String[] args){&nbsp;</div>
<div>&nbsp; &nbsp; &nbsp; &nbsp; final byte[] keyBytes = createSecretKey(); &nbsp; &nbsp;</div>
<div>&nbsp; &nbsp; &nbsp; &nbsp; String key= new BASE64Encoder().encode(keyBytes);</div>
<div>&nbsp; &nbsp; &nbsp; &nbsp; String szSrc = "admin";</div>
<div>&nbsp; &nbsp; &nbsp; &nbsp; System.out.println("加密前的字符串:" + szSrc);</div>
<div>&nbsp; &nbsp; &nbsp; &nbsp; String password = encryptMode(key,szSrc);</div>
<div>&nbsp; &nbsp; &nbsp; &nbsp; System.out.println("加密后的字符串:" + password);</div>
<div><span class="Apple-tab-span" style="white-space:pre">	</span>String result = decryptMode(key, password);</div>
<div>&nbsp; &nbsp; &nbsp; &nbsp; System.out.println("解密后的字符串:" + result);</div>
<div>&nbsp; &nbsp; }</div>
<div>}</div>
<div><br />
</div>
<div>数据库表中有一个字段用于保存Key，一个字段用于保存password,更改密码的时候，重新生成一个KEY,然后生成一个PASSWORD,匹配保存到数据库中。</div>
<div>当登陆时，用数据库保存的KEY和password进行解密，然后与登陆时输入的password进行比较，如果相等，则成功。</div>
<div>算法支持<span style="color: #4e9072; font-family: Monaco; font-size: 11px; line-height: normal;">AES,DES,DESede,Blowfish等算法</span></div><img src ="http://www.blogjava.net/lyyb2001/aggbug/423881.html" width = "1" height = "1" /><br><br><div align=right><a style="text-decoration:none;" href="http://www.blogjava.net/lyyb2001/" target="_blank">skycity</a> 2015-03-27 10:50 <a href="http://www.blogjava.net/lyyb2001/archive/2015/03/27/423881.html#Feedback" target="_blank" style="text-decoration:none;">发表评论</a></div>]]></description></item><item><title>正则匹配</title><link>http://www.blogjava.net/lyyb2001/archive/2015/03/27/423879.html</link><dc:creator>skycity</dc:creator><author>skycity</author><pubDate>Fri, 27 Mar 2015 02:41:00 GMT</pubDate><guid>http://www.blogjava.net/lyyb2001/archive/2015/03/27/423879.html</guid><wfw:comment>http://www.blogjava.net/lyyb2001/comments/423879.html</wfw:comment><comments>http://www.blogjava.net/lyyb2001/archive/2015/03/27/423879.html#Feedback</comments><slash:comments>0</slash:comments><wfw:commentRss>http://www.blogjava.net/lyyb2001/comments/commentRss/423879.html</wfw:commentRss><trackback:ping>http://www.blogjava.net/lyyb2001/services/trackbacks/423879.html</trackback:ping><description><![CDATA[@import url(http://www.blogjava.net/CuteSoft_Client/CuteEditor/Load.ashx?type=style&file=SyntaxHighlighter.css);@import url(/css/cuteeditor.css);
<p style="margin: 0px; font-size: 11px; line-height: normal; font-family: Monaco; color: #3933ff;"><span style="color: #931a68">public</span><span style="color: #000000"> </span><span style="color: #931a68">static</span><span style="color: #000000"> String </span><span style="color: #0326cc">readString</span><span style="color: #000000"> = </span>"Print([QDT],[Read([SQLServer#10.176.1.178#Mas2006],[select top 1 print_model + '.jasper' as reportname from tbl_mas_print_stru where Machine_No='SS110521Z8'],['@@Lang'])],[Read([SQLServer#10.176.1.178#Mas2006],[select&nbsp; Machine_No, Check_Code, Model_Packing, Start_Date, Material_Name, Material_No, IIPC_part_code, Material_Qty, Print_Order, Machine_Product_No, print_model, SoftWareName, SoftWare_No, SoftWareQty from dbo.tbl_mas_print_stru where Machine_No='SS110521Z8'],['@@Lang'])])"<span style="color: #000000">;</span></p>
<p style="margin: 0px; font-size: 11px; line-height: normal; font-family: Monaco; min-height: 15px;"><br />
</p>
<p style="margin: 0px; font-size: 11px; line-height: normal; font-family: Monaco;"><span class="Apple-tab-span" style="white-space:pre">	</span><span style="color: #931a68">public</span> <span style="color: #931a68">static</span> <span style="color: #931a68">void</span> splitScriptWithMethod(String <span style="color: #7e504f">script</span>) {</p>
<p style="margin: 0px; font-size: 11px; line-height: normal; font-family: Monaco; color: #4e9072;"><span style="color: #000000"><span class="Apple-tab-span" style="white-space:pre">		</span></span>// check if <span style="text-decoration: underline">args</span></p>
<p style="margin: 0px; font-size: 11px; line-height: normal; font-family: Monaco;"><span class="Apple-tab-span" style="white-space:pre">		</span>String <span style="color: #7e504f">subMethodReg</span> = <span style="color: #3933ff">""</span>;</p>
<p style="margin: 0px; font-size: 11px; line-height: normal; font-family: Monaco;"><span class="Apple-tab-span" style="white-space:pre">		</span><span style="color: #931a68">if</span>(<span style="color: #7e504f">script</span>.indexOf(<span style="color: #3933ff">"Read(["</span>) !=<span style="color: #7e504f">script</span>.lastIndexOf(<span style="color: #3933ff">"Read(["</span>)){</p>
<p style="margin: 0px; font-size: 11px; line-height: normal; font-family: Monaco; color: #3933ff;"><span style="color: #000000"><span class="Apple-tab-span" style="white-space:pre">			</span></span><span style="color: #7e504f">subMethodReg</span><span style="color: #000000"> = </span>"(.+)\\(\\[(.+)\\],\\[(.+\\(\\[.+\\]\\))\\],\\[(.+\\(\\[.+\\]\\))\\]"<span style="color: #000000">;</span></p>
<p style="margin: 0px; font-size: 11px; line-height: normal; font-family: Monaco;"><span class="Apple-tab-span" style="white-space:pre">		</span>}<span style="color: #931a68">else</span>{</p>
<p style="margin: 0px; font-size: 11px; line-height: normal; font-family: Monaco; color: #3933ff;"><span style="color: #000000"><span class="Apple-tab-span" style="white-space:pre">			</span></span><span style="color: #7e504f">subMethodReg</span><span style="color: #000000"> = </span>"(.+)\\(\\[(.+)\\],\\[(.+)\\],\\[(.+\\(\\[.+\\]\\))\\]"<span style="color: #000000">;</span></p>
<p style="margin: 0px; font-size: 11px; line-height: normal; font-family: Monaco;"><span class="Apple-tab-span" style="white-space:pre">		</span>}</p>
<p style="margin: 0px; font-size: 11px; line-height: normal; font-family: Monaco;"><span class="Apple-tab-span" style="white-space:pre">		</span>Pattern <span style="color: #7e504f">p</span> = Pattern.compile(<span style="color: #7e504f">subMethodReg</span>);</p>
<p style="margin: 0px; font-size: 11px; line-height: normal; font-family: Monaco;"><span class="Apple-tab-span" style="white-space:pre">		</span>Matcher <span style="color: #7e504f">matcher</span> = <span style="color: #7e504f">p</span>.matcher(<span style="color: #0326cc">readString</span>);</p>
<p style="margin: 0px; font-size: 11px; line-height: normal; font-family: Monaco;"><span class="Apple-tab-span" style="white-space:pre">		</span><span style="color: #931a68">while</span> (<span style="color: #7e504f">matcher</span>.find()) {</p>
<p style="margin: 0px; font-size: 11px; line-height: normal; font-family: Monaco;"><span class="Apple-tab-span" style="white-space:pre">			</span><span style="color: #931a68">for</span> (<span style="color: #931a68">int</span> <span style="color: #7e504f">i</span> = 1; <span style="color: #7e504f">i</span> &lt;= <span style="color: #7e504f">matcher</span>.groupCount(); <span style="color: #7e504f">i</span>++) { &nbsp;</p>
<p style="margin: 0px; font-size: 11px; line-height: normal; font-family: Monaco;"><span class="Apple-tab-span" style="white-space:pre">	</span>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; System.<span style="color: #0326cc">out</span>.println(<span style="color: #3933ff">"grp "</span> + <span style="color: #7e504f">i</span> + <span style="color: #3933ff">" :"</span> + <span style="color: #7e504f">matcher</span>.group(<span style="color: #7e504f">i</span>)); &nbsp;</p>
<p style="margin: 0px; font-size: 11px; line-height: normal; font-family: Monaco;"><span class="Apple-tab-span" style="white-space:pre">	</span>&nbsp; &nbsp; &nbsp; &nbsp; }&nbsp;</p>
<p style="margin: 0px; font-size: 11px; line-height: normal; font-family: Monaco;"><span class="Apple-tab-span" style="white-space:pre">		</span>}</p>
<p style="margin: 0px; font-size: 11px; line-height: normal; font-family: Monaco;"><span class="Apple-tab-span" style="white-space:pre">	</span>}</p>
<p style="margin: 0px; font-size: 11px; line-height: normal; font-family: Monaco;"><br />
</p>
<p style="margin: 0px; font-size: 11px; line-height: normal; font-family: Monaco;"><br />
</p>
<p style="margin: 0px; font-size: 11px; line-height: normal; font-family: Monaco;">grp 1 :Print</p>
<p style="margin: 0px; font-size: 11px; line-height: normal; font-family: Monaco;">grp 2 :QDT</p>
<p style="margin: 0px; font-size: 11px; line-height: normal; font-family: Monaco;">grp 3 :Read([SQLServer#10.176.1.178#Mas2006],[select top 1 print_model + '.jasper' as reportname from tbl_mas_print_stru where Machine_No='SS110521Z8'],['@@Lang'])</p>
<p style="margin: 0px; font-size: 11px; line-height: normal; font-family: Monaco;">
</p>
<p style="margin: 0px; font-size: 11px; line-height: normal; font-family: Monaco;">grp 4 :Read([SQLServer#10.176.1.178#Mas2006],[select&nbsp; Machine_No, Check_Code, Model_Packing, Start_Date, Material_Name, Material_No, IIPC_part_code, Material_Qty, Print_Order, Machine_Product_No, print_model, SoftWareName, SoftWare_No, SoftWareQty from dbo.tbl_mas_print_stru where Machine_No='SS110521Z8'],['@@Lang'])</p>
<div><br />
</div>
<div><span style="color: #3933ff; font-family: Monaco; font-size: 11px; line-height: normal;">其中，用于匹配(.+)\\(\\[(.+)\\],\\[(.+\\(\\[.+\\]\\))\\],\\[(.+\\(\\[.+\\]\\))\\],print([],[Read([],[],[])],[Read([],[],[])])这样的结构</span></div>
<div><span style="color: #3933ff; font-family: Monaco; font-size: 11px; line-height: normal;">而(.+)\\(\\[(.+)\\],\\[(.+)\\],\\[(.+\\(\\[.+\\]\\))\\]，用于匹配print([],[],[Read([],[],[])]这样的结构</span></div><img src ="http://www.blogjava.net/lyyb2001/aggbug/423879.html" width = "1" height = "1" /><br><br><div align=right><a style="text-decoration:none;" href="http://www.blogjava.net/lyyb2001/" target="_blank">skycity</a> 2015-03-27 10:41 <a href="http://www.blogjava.net/lyyb2001/archive/2015/03/27/423879.html#Feedback" target="_blank" style="text-decoration:none;">发表评论</a></div>]]></description></item></channel></rss>