14:18 2014/5/5IOC inversion of control 控制反转
将new对象的权力由调用者转移到spring容器(即xml文件),Struts2与Spring整合(scope="prototype")由spring来维护struts的生命周期,在启动web容器时spring容...
分类:
其他好文 时间:
2014-05-23 05:56:11
阅读次数:
284
从一个List中移除重复的数据使用迭代方法会报异常:java.util.ConcurrentModificationExceptionMap
temp = new HashMap();for (GroupRule rule : ruleList) { String ruleName =
rule.....
分类:
其他好文 时间:
2014-05-23 05:41:56
阅读次数:
187
第一种:借助于BindingSourcesqlDataReader
Sdr=通过查询函数得到的sqlDataReader类型的数据;BindingSource Bs=new BindingSource()
;Bs.DataSource=Sdr;DataGridView.DataSource=Bs;第...
Given a sorted array, remove the duplicates in
place such that each element appear onlyonceand return the new length.Do not
allocate extra space for a...
分类:
其他好文 时间:
2014-05-21 20:00:51
阅读次数:
296
asp.net MVC4.0中总结 视图里加载部分视图几种方法@RenderPage()但它不能使用
原来视图的 Model 和 ViewData ,只能通过参数来传递。1
@RenderPage("~/Shared/Component/Dialog.cshtml", new { title = "...
分类:
Web程序 时间:
2014-05-21 17:47:46
阅读次数:
380
记录一些典型的Java代码。一、文件读取 1 public class Test4 { 2
public static void main(String[] args) { 3 try { 4 FileReader fdFileReader=new
F...
分类:
编程语言 时间:
2014-05-21 17:39:52
阅读次数:
259
public class ArrayUtils{
/**
* 返回数组最大值
*
* @param a
* @return
*/
public static int max(int[] a){
// 返回数组最大值
int x;
int aa[]=new int[a.leng...
分类:
编程语言 时间:
2014-05-21 13:31:26
阅读次数:
373
String到底创建了几个对象的自己的理解。(字节码层面上)...
分类:
其他好文 时间:
2014-05-21 13:21:13
阅读次数:
266
1、在进入系统的时候经常提示Youhavenewmailin/var/spool/mail/rootecho“unsetMAILCHECK”>>/etc/profilesource/etc/profile关闭sendmail的功能:chmod0/usr/sbin/sendmailmv/usr/sbin/sendmail/usr/sbin/sendmail.bakln-s/var/qmail/bin/sendmail/usr/sbin/sendmail清..
分类:
其他好文 时间:
2014-05-21 12:39:10
阅读次数:
278
析构函数和构造函数是一对,就像C语言中的malloc和free,C++中的new和delete一样
先从一个实例说起:
#include
#include
using namespace std;
class Student
{
public:
Student(int n, string nam, char s)
{
num = n;
name = nam;
sex...
分类:
其他好文 时间:
2014-05-21 12:33:43
阅读次数:
259