`
rooi
  • 浏览: 52560 次
  • 性别: Icon_minigender_1
  • 来自: 深圳
社区版块
存档分类
最新评论
  • rooi: int statusCode =  response.getS ...
    RTC
  • rooi: package com.coamctech.bxloan.co ...
    RTC
  • rooi: establishConnectionTimeout
    RTC
  • rooi: http://www.cnblogs.com/admol/ar ...
    RTC
  • rooi: https://github.com/qbektrix/xml ...
    RTC

RTC

 
阅读更多
https://github.com/loiane/curso-extjs4

http://blog.csdn.net/leimengyuanlian/article/details/18748599

https://github.com/loiane/extjs4-first-look

http://www.cnblogs.com/fsjohnhuang/archive/2013/03/06/2945311.html

https://github.com/kdnc/spring-exercises/blob/110558a972e36cc58bd45851a87ebe4b485f1c54/b-peadweas-task-time-tracker/src/main/webapp/app/Application.js

https://github.com/fharenheit/flamingo-hadoop-manager-oozie/tree/2cb42263a94787d366a65c12c11d6b2bcd89c91f/src/main/webapp/resources/js/ext4-highchart-ext/Chart/ux
http://www.qeefee.com/article/extjs-mvc-in-detail


http://extjs-doc-cn.github.io/ext4api/


http://www.cnblogs.com/fsjohnhuang/archive/2013/02/19/2917233.html


https://github.com/weishengshui/jxt_01/blob/f9ec7e4de481873b1063f564b5716bedadeba8f7/metro/src/main/webapp/WEB-INF/views/brand/list.jsp
https://github.com/gripson/EIMS/blob/cc79bb4135f209ecc6f3b36dc643ccd7b3f428ff/app/views/Application/employee.html

select t.user_def4,case when t.user_def5 = 2300 then 2700  when t.user_def5 = 2700 then 2900 end from push_tb_has_been_send_data d,push_tb_has_been_send_data_detail t where d.id = t.send_data_link_id and
d.company_code = '5715920351' and d.int_code = 'SALE_ORDER_STATUS_PUSH_SERVICE'  and d.create_tm > '2017-01-07' and d.create_tm < '2017-01-07 14:08:57' ;


<xsl:stylesheet
  xmlns:xsl="http://www.w3.org/1999/XSL/Transform" version="1.0"
  xmlns="http://www.w3.org/TR/REC-html40">

  <!-- FileName: misc-evans -->
  <!-- Document: http://www.w3.org/TR/xslt -->
  <!-- DocVersion: 19991116 -->
  <!-- Purpose: COPY of perf test;"A Practical Suggestion for XSLT Performance Improvement" by Clark Evans. -->

   <xsl:variable name="day-list"
     select="//dow[not(.=following::dow)]" />

   <xsl:variable name="product-list"
            select="//product[not(.=following::product)]" />
    
<xsl:template match="/">
  <xsl:variable name="my-test"><a><b/></a></xsl:variable>
  <html>
    <xsl:copy-of select="$my-test"/>
    <body>
    <table>
      <tr>
        <td><xsl:text> </xsl:text></td>
        <xsl:for-each select="$day-list">
          <xsl:sort order="ascending" select="." />
          <th><xsl:value-of select="."/></th>
        </xsl:for-each>
      </tr>
      <xsl:for-each select="$product-list">
        <xsl:sort    order="ascending" select="." />
        <xsl:variable name="product" select="." />
        <tr>
          <td>
            <xsl:value-of select="$product" />
          </td>
          <xsl:for-each select="$day-list">
            <xsl:sort order="ascending" select="." />
            <xsl:variable name="day" select="." />
            <td>
              <xsl:value-of
             select="sum(//price[../product=$product][../../../dow=$day])"
/> .
            </td>
          </xsl:for-each>
          <td>
            <xsl:value-of
              select="sum(//price[../product=$product])" /> .
           </td>
        </tr>
      </xsl:for-each>
      <tr>
        <td><xsl:text> </xsl:text></td>
        <xsl:for-each select="$day-list">
          <xsl:sort    order="ascending" select="." />
          <xsl:variable name="day" select="." />
          <td>
            <xsl:value-of
              select="sum(//price[../../../dow=$day])" />
          </td>
        </xsl:for-each>
        <td>
          <xsl:value-of select="sum(//price)" />
        </td>
      </tr>
    </table>
    </body>
  </html>
</xsl:template>
</xsl:stylesheet>


<upload>
  <day>
    <dow>tue</dow>
    <order>
      <line>
         <product>Belt</product>
         <price>5.54</price>
      </line>
    </order>
  </day>
  <day>
    <dow>wed</dow>
  </day>
  <day>
    <dow>thu</dow>
    <order>
      <line>
         <product>Boots</product>
         <price>9.23</price>
      </line>
    </order>
  </day>
  <day>
    <dow>fri</dow>
    <order>
    </order>
    <order>
    </order>
  </day>
  <day>
    <dow>sat</dow>
    <order>
      <line>
         <product>Jacket</product>
         <price>9.84</price>
      </line>
    </order>
  </day>
  <day>
    <dow>mon</dow>
    <order>
    </order>
    <order>
      <line>
         <product>Tie</product>
         <price>5.37</price>
      </line>
    </order>
  </day>
  <day>
    <dow>tue</dow>
  </day>
  <day>
    <dow>wed</dow>
    <order>
    </order>
  </day>
  <day>
    <dow>thu</dow>
    <order>
      <line>
         <product>Overalls</product>
         <price>3.16</price>
      </line>
    </order>
  </day>
</upload>

http://www.cnblogs.com/jeremyyang824/p/5856353.html

http://www.cnblogs.com/admol/articles/4248159.html

http://blog.csdn.net/happylife_haha/article/details/51993350

<!-- https://mvnrepository.com/artifact/org.jboss.resteasy/resteasy-jaxrs -->
<dependency>
    <groupId>org.jboss.resteasy</groupId>
    <artifactId>resteasy-jaxrs</artifactId>
    <version>3.1.1.Final</version>
</dependency>
  • 1.zip (6.3 MB)
  • 下载次数: 2
  • 2.zip (4.7 MB)
  • 下载次数: 2
  • 1.rar (1.5 MB)
  • 下载次数: 4
  • 123.zip (19.9 KB)
  • 下载次数: 1
  • w.zip (1 MB)
  • 下载次数: 2
  • 44.zip (312.5 KB)
  • 下载次数: 2
  • 123.7z (1.7 MB)
  • 下载次数: 3
分享到:
评论
30 楼 rooi 2018-05-19  
int statusCode =  response.getStatusLine().getStatusCode();
if(statusCode==200 && "application/pdf".equals(response.getFirstHeader("Content-Type").getValue())){
HttpEntity httpEntity=response.getEntity();
if(!httpEntity.isRepeatable()){
httpEntity = new BufferedHttpEntity(httpEntity);
}

ByteArrayInputStream content = (ByteArrayInputStream) httpEntity.getContent();
char[] encode = Hex.encode(DigestUtils.sha256(content));
content.reset();
Pdf2Images(content,new String(encode));
}
29 楼 rooi 2018-04-11  
package com.coamctech.bxloan.commons.webservices;



import java.util.HashMap;
import java.util.Map;
import java.util.Properties;

import org.apache.cxf.endpoint.Client;
import org.apache.cxf.jaxws.endpoint.dynamic.JaxWsDynamicClientFactory;
import org.apache.cxf.transport.http.HTTPConduit;
import org.apache.cxf.transports.http.configuration.HTTPClientPolicy;
import org.springframework.stereotype.Component;

import com.coamctech.bxloan.commons.utils.Utils;
import com.coamctech.bxloan.commons.GlobalConstants;


@Component
public class WebServices {

private static final String WS_CONFIG = "webservices.properties";

private static Properties config = Utils.loadPropertiesFileFromClassPath(WS_CONFIG);

private static JaxWsDynamicClientFactory dcf = JaxWsDynamicClientFactory.newInstance();

private Map<String, Client> clients = new HashMap<String, Client>();

/**
* 一次性初始化所有WebServices,对于需要调用的服务属于强依赖
* 若需要调用的WebServices有一个未启动,则导致后续WebServices都不能正常初始化
*/
@Deprecated
public void initClients() {
JaxWsDynamicClientFactory dcf = JaxWsDynamicClientFactory.newInstance();
Properties config = Utils.loadPropertiesFileFromClassPath(WS_CONFIG);
for (String serviceName : config.stringPropertyNames()) {
String wsdlUrl = config.getProperty(serviceName);
Client client = dcf.createClient(wsdlUrl);
HTTPConduit httpConduit = (HTTPConduit) client.getConduit();
HTTPClientPolicy policy = new HTTPClientPolicy();
// policy.setConnectionTimeout(1); //连接超时时间
policy.setReceiveTimeout(5000); //请求超时时间
httpConduit.setClient(policy);
clients.put(serviceName, client);
}
}

private Client initClient(String serviceName) {
Client client = clients.get(serviceName);
if (client == null) {
String wsdlUrl = config.getProperty(serviceName);
client = dcf.createClient(wsdlUrl);
HTTPConduit httpConduit = (HTTPConduit) client.getConduit();
HTTPClientPolicy policy = new HTTPClientPolicy();
// policy.setConnectionTimeout(1); //连接超时时间
policy.setReceiveTimeout(GlobalConstants.CONN_RISK_TIME); //请求超时时间
httpConduit.setClient(policy);
clients.put(serviceName, client);
}
return client;
}
/**
* 调用WebServices方法
* @param serviceName WebServices服务名(对应ws.properties里的key)
* @param methodName 调用的方法名
* @param params 参数
* @return json字符串
* @throws Exception
*/
public String invoke(String serviceName, String methodName, Object... params) throws Exception {
Client client = initClient(serviceName);
return (String) client.invoke(methodName, params)[0];
}
}
28 楼 rooi 2017-06-14  
establishConnectionTimeout
27 楼 rooi 2017-03-30  
http://www.cnblogs.com/admol/articles/4248159.html

http://blog.csdn.net/happylife_haha/article/details/51993350
26 楼 rooi 2016-09-22  
https://github.com/qbektrix/xml2json-xslt/issues/3
25 楼 rooi 2016-09-22  
<xsl:template match="*[count(../*[name(../*)=name(.)])=count(../*) and
count(../*)&gt;1]">
    <xsl:if test="not(preceding-sibling::*)">[</xsl:if>
    <xsl:choose>
      <xsl:when test="not(child::node())">
        <xsl:text>null</xsl:text>
      </xsl:when>
      <xsl:otherwise>
        <xsl:apply-templates select="child::node()"/>
      </xsl:otherwise>
    </xsl:choose>
    <xsl:if test="following-sibling::*">,</xsl:if>
    <xsl:if test="not(following-sibling::*)">]</xsl:if>
  </xsl:template>
24 楼 rooi 2016-08-18  
[pre]    当进行XML数据转换的时候,我们经常会碰到XML数据文件中含有重复的元素。在这封技
术邮件中,我们将讨论一种解决该问题的方法。
问题:
    让我们先来看一下具体的问题描述。假使有如下的一个XML数据文件,它包含了如下的内容:[/pre]
<Order>
  <Item number="1">
    <SKU>12345</SKU>
    <Description>Standard Widget</Description>
  </Item>
  <Item number="2">
    <SKU>54321</SKU>
    <Description>Turbo Widget</Description>
  </Item>
  <Item number="3">
    <SKU>12345</SKU>
    <Description>Standard Widget</Description>
  </Item>
</Order>

[pre]    在上面的XML数据文件中,每个Item元素都是单独显示的,请注意Item number1和Item number3
中的数据是一样的。但是,需求目标要求输出的XML数据文件中每个SKU元素个体不能重复,
并且要加上一个新的<Quantity>元素以显示每个Item元素数据的个数。需求目标的输出文件如下:[/pre]
<Order>
  <Item>
    <Quantity>2</Quantity>
    <SKU>12345</SKU>
    <Description>Standard Widget</Description>
  </Item>
  <Item>
    <Quantity>1</Quantity>
    <SKU>54321</SKU>
    <Description>Turbo Widget</Description>
  </Item>
</Order>

解决方法:

[pre]    提出的问题实际上有两个问题需要解决。第一,需要去除重复的SKU#12345元素个体(entry);
第二,需要提供一个新的<Quantity>元素以显示每个Item元素数据的个数。为了解决这些问
题,我们得使用一些XSLT的高级特性。
    为了解决第一个问题,我们将使用XSLT的following操作。following和preceding操作
分别指示在一个for-each循环中的以后和以前节点(node)。following操作判断以后节点
如果和当前节点一样,则去除当前重复的节点。
    为了解决第二个问题,我们需要得到每个Item元素的个数。幸运的是,XSLT提供计数(count)
功能。使用计数功能,我们可以对XML数据文件中出现的每个Item元素进行计数,并将这个
数值赋值给新建的<Quantity>元素。[/pre]
去除重复的元素个体:

[pre]    去除重复的元素个体需要一些小技巧。首先,将选择的节点放入一个for-each循环中,
但是这个循环中的select属性值需要一些小技巧。通常的做法,你会将所有的Item放入for-each
循环中,如下:[/pre]
<xsl:for-each select="//Order/Item">
. . .
</xsl:for-each>

[pre]    但是,我们需要每个SKU元素数据都唯一。为了能达到这种转换,我们得在select的属
性值中加入额外的信息。这个额外的信息将会告诉转换处理器只对以后节点和当前节点不同
的当前节点取值。举个小例子,如果第一个节点是A,下一个节点是A,那么就忽略第一个节
点;如果第一个节点是A,下一个节点是A,再下一个节点是B,那么循环之后对第二个节点
取值,第一个节点会被忽略。下面是该方法在XML的表达式:[/pre]
<xsl:for-each select="//SKU[not(.=following::SKU)]">
. . .
</xsl:for-each>

[pre]    在上面的XML表达式中,select的属性值决定了怎样循环取值选择的节点数据。它使得
我们只对以后节点和当前节点(用.表示)不同的当前节点取值。[/pre]
计数:

[pre]    需要对每个SKU元素进行计数并把它赋值给新建的<Quantity>元素,同样需要一些小技
巧。我们可以使用XSLT的计数(count)功能,但难题是告诉转换处理器需要对那些元素计数。
一个对所有SKU元素计数的简单例子如下:[/pre]
<xsl:value-of select="count(//SKU)"/>

[pre]    上面的XML表达式中,只是简单的对所有符合//SKU模式的元素进行计数。但是,我们需
要的是对满足特殊条件的SKU元素计数。技巧之处在于满足特殊条件的SKU元素值在每个for-each
循环中可以得到,并且是用点号(.)标识。那么解决计数问题的关键就是计数(count)功
能也需要使用点号(.)标识。所以,我们可以在每个for-each循环中,使用一个新变量,
如下所示:[/pre]
<xsl:variable name="thesku" select="."/>

[pre]    接着,我们就可以使用计数(count)功能来对每个SKU元素进行计数了,如下所示:[/pre]
<Quantity><xsl:value-of select="count(//SKU[.=$thesku])"/></Quantity>

完整的解决方法:

[pre]    现在,我们可以把以上所述的所有内容合并起来,得到该问题的完整解决方法。下面的
完整代码使用select属性来对SKU进行唯一性选择;而<Quantity>元素是使用计数XSLT的(count)
功能得到的;最后,<Description>元素的值是从原XML数据文件取值而来。[/pre]
<?xml version="1.0" encoding="UTF-8"?>
<xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
  <xsl:template match="/">
    <Order>
      <xsl:for-each select="//SKU[not(.=following::SKU)]">
        <xsl:variable name="thesku" select="."/>
        <Item>
          <Quantity><xsl:value-of select="count(//SKU[.=$thesku])"/></Quantity>
          <SKU><xsl:value-of select="." /></SKU>
          <Description><xsl:value-of select="../Description"/></Description>
        </Item>
      </xsl:for-each>
    </Order>
  </xsl:template>
</xsl:stylesheet>

[pre]编者注释:由于技术错误,在先前的XML技术邮件"Tokenizing strings with Xalan-Java"
(March 20, 2002)中,里面的代码有一个错误,特此更正,完整正确的代码如下:[/pre]
To use the tokenize function, we'll create a template that calls it, like the following:
<?xml version="1.0" encoding="UTF-8"?>
<xsl:stylesheet version="1.0"
xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
xmlns:xalan="http://xml.apache.org/xalan">
  <xsl:template match="/">
    <xsl:for-each select="//CustomerAddress">
<Address><xsl:value-of select="Address1"/></Address>
<City><xsl:value-of select="xalan:tokenize(Address2, ' ,')[1]"/></City>
<State><xsl:value-of select="xalan:tokenize(Address2, ' ,')[2]"/></State>
<Zip><xsl:value-of select="xalan:tokenize(Address2, ' ,')[3]"/></Zip>
    </xsl:for-each>
  </xsl:template>
</xsl:stylesheet>
23 楼 rooi 2016-08-18  
<?xml version="1.0" encoding="ISO-8859-1"?><xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform"><xsl:template match="/"><SaleEnvelope><xsl:for-each select="/SaleEnvelope/SaleList"><SaleList><xsl:for-each select="Invoice"><xsl:if test="not(contains(Surname,'Shop'))"><Statement><xsl:attribute name="Type">Monthly</xsl:attribute><xsl:attribute name="Style">Full</xsl:attribute><Customer><Initials><xsl:for-each select="Initial"><xsl:value-of select="."/></xsl:for-each></Initials><Name><xsl:value-of select="Surname"/></Name><Balance><xsl:value-of select="Balance"/></Balance></Customer><Purchases><xsl:for-each select="Item"><Article><Desc><xsl:value-of select="Description"/></Desc><Cost><xsl:value-of select='format-number((number(Price)*1.6),"####.##")'/></Cost><Qty><xsl:value-of select="Quantity"/></Qty></Article></xsl:for-each></Purchases><Amount><xsl:attribute name="Currency"><xsl:value-of select="Currency" /></xsl:attribute><xsl:call-template name="sumSales"><xsl:with-param name="list" select="Item"/></xsl:call-template></Amount></Statement></xsl:if></xsl:for-each></SaleList></xsl:for-each></SaleEnvelope></xsl:template><xsl:template name="sumSales"><xsl:param name="list" /><xsl:param name="result"  select="0"/><xsl:choose><xsl:when test="$list"><xsl:call-template name="sumSales"><xsl:with-param name="list"
select="$list[position()!=1]"/><xsl:with-param name="result"
select="$result + number($list[1]/Price)*number($list[1]/Quantity)*1.6"/></xsl:call-template></xsl:when><xsl:otherwise><xsl:value-of select='format-number(number($result),"####.##")'/></xsl:otherwise></xsl:choose></xsl:template></xsl:stylesheet>
22 楼 rooi 2016-06-28  
flexible="true"
21 楼 rooi 2016-06-21  
<binding name="Binding" package="com.vteba.service.xml.jibx">
  <include path="service_xml_jibxBinding.xml"/>
  <include path="service_xmlBinding.xml"/>
</binding>
20 楼 rooi 2016-03-26  
https://chrome.google.com/webstore/detail/lgllffgicojgllpmdbemgglaponefajn
19 楼 rooi 2016-01-04  
http://blog.csdn.net/u011983111/article/details/49021817
18 楼 rooi 2015-12-21  
=CONCATENATE("update rule_tb_exch_field_map set def_value =  '"&G2&"',update_tm=now() where tpl_code = '"&A2&"_SALE_ORDER_WS_TO_SIM' and out_catalog_code='"&IF(B2="lscm_ta_order_header","221",IF(B2="lscm_ta_order_detail","9999","ERR"))&"' ;")
17 楼 rooi 2015-09-20  
http://blog.csdn.net/aerchi/article/details/41077613
16 楼 rooi 2015-08-18  
insertRow  beginedit endEdit onDblClickRow rejectChanges
15 楼 rooi 2015-08-18  
https://github.com/lernalot/lernalot.github.io/blob/4fb12a3ad017ad29548e9dc8fd536336af994631/personal-program/expo%EF%BC%88personal-firefox%EF%BC%89/webpage/forum/program.js
14 楼 rooi 2015-08-09  
com.fasterxml.jackson.annotation.JsonProperty
13 楼 rooi 2015-07-19  
$(":checkbox[name=cb]").click(function(){
if($(this).attr("checked")!=undefined)
{
$(this).siblings().attr("checked",false);
$(this).attr("checked",true);
}


$(function(){

$('#aixuexi').children('input[type=checkbox]').click(function(){

if($(this).is(':checked')){

$(this).attr('checked',true).siblings().attr('checked',false);



}else{

$(this).attr('checked',false).siblings().attr('checked',false);

}  })

})
12 楼 rooi 2015-07-13  
http://103.3.61.88:8081/nexus/content/repositories/lv-snapshot/com/lv/admin/0.0.1-SNAPSHOT/
11 楼 rooi 2015-06-03  
https://github.com/lespinoza1/yablog/blob/59950e8b6ce6862ac54c66a07166a15f86656320/jeasyui/study/layout/js/jeasyui.overrides.js

相关推荐

Global site tag (gtag.js) - Google Analytics