07 2013 档案
摘要:Ext.onReady(function(){ Ext.create('Ext.data.Store', { storeId:'simpsonsStore', fields:['name', 'email', 'phone'], data:{'items':[ { 'name': 'Lisa', "email":"lisa@simpsons.com", "phone":"555-111-1224&q
阅读全文
摘要:Ext.dom.QueryElement Selectors:(元素选择器)Ext.core.DomQuery.select('表达式') 返回HTMLElement[]*any elementExt.core.DomQuery.select('*') //返回所有dom元素Ean element with the tag EExt.core.DomQuery.select('div') //返回所有div元素E FAll descendent elements of E that have the tag FExt.core.DomQuery.
阅读全文
摘要:[].concat([],[]); 合并俩个数组[].concat([]) 合并俩个数组[].join(",") 使用给定,连接该数组 a,b,c
阅读全文
摘要:Using a ProxyExt.define('User', { extend: 'Ext.data.Model', fields: ['id', 'name', 'email'], proxy: { type: 'rest', url : '/users' }});当在Model中定义了一个Proxy以后就可以使用 save,update,load,destroy这4个方法 进行增删改查操作var user = Ext.create('User', {name:
阅读全文
摘要:第一步. 定义后:每个已定义函数,都有一个内在属性[scope],其对应一个对象的列表,列表中的对象仅能内部访问。例如:建立一个全局函数A,那么A的[Scope]内部属性中只包含一个全局对象(Global Object),而如果我们在A中创建一个新的函数B,那么B的[Scope]属性中就包含两个对象...
阅读全文
摘要:Spring Validatehttp://haohaoxuexi.iteye.com/blog/1812584
阅读全文
摘要:SpringMVC之类型转换Converter详解本文转载http://www.tuicool.com/articles/uUjaum1.1目录1.1目录1.2前言1.3Converter接口1.4ConversionService接口1.5ConverterFactory接口1.6GenericConverter接口1.6.1概述1.6.2ConditionalGenericConverter接口1.2前言在以往我们需要SpringMVC为我们自动进行类型转换的时候都是用的PropertyEditor。通过PropertyEditor的setAsText()方法我们可以实现字符串向特定类型的
阅读全文
摘要:@RequestMapping 用法详解之地址映射http://blog.csdn.net/walkerjong/article/details/7994326
阅读全文
摘要:通过分析源代码解决动态加载Controller的问题最近在研究ExtJs(4.2.0)的MVC开发模式,具体Extjs的MVC如何使用这里不解释,具体参见ExtJs的官方文档。这里要解决的问题是如何解决在使用MVC模式时动态加载Controller。这是正常的写法,在Application里配置ControllerApplicationExt.application({ ... controllers: [ 'Users' ], ...});ControllerExt.define('AM.controller.Users', { extend: '..
阅读全文
摘要:/** * 系统通用下拉选择Gird */Ext.define("Common.picker.GridPicker", { extend: "Ext.form.field.Picker", alias: 'widget.gridPicker', displayField: null, valueField: null, matchFieldWidth: false, store: null, columns: null, pickerWidth: 400, pickerHeight: ...
阅读全文
摘要:在Condition中,用await()替换wait(),用signal()替换notify(),用signalAll()替换notifyAll(),传统线程的通信方式,Condition都可以实现,这里注意,Condition是被绑定到Lock上的,要创建一个Lock的Condition必须用newCondition()方法。这样看来,Condition和传统的线程通信没什么区别,Condition的强大之处在于它可以为多个线程间建立不同的Condition,下面引入API中的一段代码,加以说明。class BoundedBuffer { final Lock lock = new R...
阅读全文
摘要:在上篇文章《多线程的使用——Thread类和Runnable接口》中提到中断线程的问题。在JAVA中,曾经使用stop方法来停止线程,然而,该方法具有固有的不安全性,因而已经被抛弃(Deprecated)。那么应该怎么结束一个进程呢?官方文档中对此有详细说明:《为何不赞成使用 Thread.stop、Thread.suspend 和 Thread.resume?》。在此引用stop方法的说明:1. Why is Thread.stop deprecated?Because it is inherently unsafe. Stopping a thread causes it to unloc
阅读全文
摘要:jre -DproxySet=true -Dhttp.proxyHost=127.0.0.1 -Dhttp.proxyPort=8888 Or:jre -DproxySet=true -DproxyHost=127.0.0.1 -DproxyPort=8888 MyAppOr, change the Java Virtual Machine's proxy settings programmatically: System.setProperty("http.proxyHost", "127.0.0.1"); System.setProperty
阅读全文
摘要:package org.apache.http.examples.client;import org.apache.http.HttpEntity;import org.apache.http.HttpHost;import org.apache.http.HttpResponse;import org.apache.http.auth.AuthScope;import org.apache.http.auth.UsernamePasswordCredentials;import org.apache.http.client.methods.HttpGet;import org.apache.
阅读全文
摘要:Tomcat性能优化之(一) 启动GZIP压缩1:设置TOMCAT启用GZIP压缩,通过浏览器HTTP访问对应的资源会根据配置进行压缩。 从上面节点的属性可以看出,要使用GZIP压缩功能,你需要在Connector节点中加上如下属性:compression="on" 启动压缩功能。compre...
阅读全文
摘要:/* * ==================================================================== * * Licensed to the Apache Software Foundation (ASF) under one or more * contributor license agreements. See the NOTICE file distributed with * this work for additional information regarding copyright ownership. * The ASF...
阅读全文
摘要:/* * ==================================================================== * Licensed to the Apache Software Foundation (ASF) under one * or more contributor license agreements. See the NOTICE file * distributed with this work for additional information * regarding copyright ownership. The ASF lice..
阅读全文
摘要:/* * ==================================================================== * * Licensed to the Apache Software Foundation (ASF) under one or more * contributor license agreements. See the NOTICE file distributed with * this work for additional information regarding copyright ownership. * The ASF...
阅读全文
摘要:public class Test { public static void main(String[] args) throws IOException { DefaultHttpClient httpclient = new DefaultHttpClient(); try { HttpPost httpost = new HttpPost("http://localhost:8080/task/index.jsp"); List nvps = new ArrayList (); ...
阅读全文
摘要:package org.apache.http.examples.client;import java.util.List;import org.apache.http.HttpEntity;import org.apache.http.HttpResponse;import org.apache.http.client.CookieStore;import org.apache.http.client.HttpClient;import org.apache.http.client.methods.HttpGet;import org.apache.http.client.protocol.
阅读全文
摘要:package org.apache.http.examples.client;import org.apache.http.HttpEntity;import org.apache.http.HttpResponse;import org.apache.http.client.HttpClient;import org.apache.http.client.methods.HttpGet;import org.apache.http.impl.client.DefaultHttpClient;/** * This example demonstrates how to abort an HT
阅读全文
摘要:package org.apache.http.examples.client;import java.io.IOException;import java.io.InputStream;import org.apache.http.HttpEntity;import org.apache.http.HttpResponse;import org.apache.http.client.HttpClient;import org.apache.http.client.methods.HttpGet;import org.apache.http.impl.client.DefaultHttpCli
阅读全文
摘要:/* * ==================================================================== * Licensed to the Apache Software Foundation (ASF) under one * or more contributor license agreements. See the NOTICE file * distributed with this work for additional information * regarding copyright ownership. The ASF lice..
阅读全文
摘要:Sencha Touch2 工作笔记Ext.dataview.Listactivate(this, newActiveItem, oldActiveItem, eOpts)Fires whenever item within the Container is activated.该事件可以解决在Ext.navigation.View容器中 点击返回按钮再次显示LIST的时候刷新问题
阅读全文