自定义博客皮肤VIP专享

*博客头图:

格式为PNG、JPG,宽度*高度大于1920*100像素,不超过2MB,主视觉建议放在右侧,请参照线上博客头图

请上传大于1920*100像素的图片!

博客底图:

图片格式为PNG、JPG,不超过1MB,可上下左右平铺至整个背景

栏目图:

图片格式为PNG、JPG,图片宽度*高度为300*38像素,不超过0.5MB

主标题颜色:

RGB颜色,例如:#AFAFAF

Hover:

RGB颜色,例如:#AFAFAF

副标题颜色:

RGB颜色,例如:#AFAFAF

自定义博客皮肤

-+
  • 博客(29)
  • 资源 (1)
  • 收藏
  • 关注

原创 web.xml AnnotationConfigWebApplicationContext

<!-- Configure ContextLoaderListener to use AnnotationConfigWebApplicationContextinstead of the default XmlWebApplicationContext -->contextClassorg.springframework.web.context.support.AnnotationC

2013-04-18 16:15:08 6493

原创 @PostConstruct and @PreDestroy example

<beans xmlns="http://www.springframework.org/schema/beans"xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"xmlns:context="http://www.springframework.org/schema/context"xsi:schemaLocation="http:

2013-04-18 14:53:44 616

原创 @Resource example

<beans xmlns="http://www.springframework.org/schema/beans"xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"xmlns:context="http://www.springframework.org/schema/context"xsi:schemaLocation="http:

2013-04-18 14:21:14 1005

原创 @Qualifier example

beans.xmlxmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"xmlns:context="http://www.springframework.org/schema/context"xsi:schemaLocation="http://www.springframework.org/schema/beansht

2013-04-18 13:57:20 1155

原创 @Autowired example

beans.xml<beans xmlns="http://www.springframework.org/schema/beans"xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"xmlns:context="http://www.springframework.org/schema/context"xsi:schemaLoc

2013-04-18 13:24:27 503

原创 @Required example

beans.xml<beans xmlns="http://www.springframework.org/schema/beans"xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"xmlns:context="http://www.springframework.org/schema/context"xsi:schemaL

2013-04-18 13:07:55 568

原创 BeanPostProcessor example

web.xml InitBean.javapackage com.vf.constructor.objectmatch;import org.apache.log4j.Logger;import org.springframework.beans.BeansException;import org.springframework.beans.factory.c

2013-04-15 10:00:36 683

原创 initialization and destroy methods in bean

web.xml Contact.javapackage com.vf.constructor.objectmatch;import org.apache.log4j.Logger;import org.springframework.context.ApplicationContext;import org.springframework.context

2013-04-12 15:56:29 527

原创 Setter-based dependency injection

web.xml WomenSerivce.javapackage com.vf.constructor.objectmatch;public class WomenSerivce { /** * @param args */ public WomenSerivce() { System.out.println("Women ser

2013-04-12 13:53:57 561

原创 Constructor argument name

web.xml ContactBean.javapackage com.vf.constructor.objectmatch;import org.springframework.context.ApplicationContext;import org.springframework.context.support.ClassPathXml

2013-04-12 11:15:15 670

原创 Constructor argument type matching

web.xml ContactBean.javapackage com.vf.constructor.objectmatch;import org.springframework.context.ApplicationContext;import org.springframework.context.support.ClassPathXml

2013-04-12 11:07:50 613

原创 Constructor argument with object matching

web.xml DrinkService.javapackage com.vf.constructor.objectmatch;public interface DrinkService {}Alcohol.javapackage com.vf.constructor.objectmatch;public class

2013-04-12 10:53:29 584

原创 Spring-Instantiation bean with a static factory method

web.xml<beans xmlns="http://www.springframework.org/schema/beans" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://www.springframework.org/schema/bea

2013-04-12 10:14:29 543

原创 java.util.Date和java.sql.Date的区别

java.util.Date 就是在除了SQL语句的情况下面使用java.sql.Date 是针对SQL语句使用的,它只包含日期而没有时间部分它都有getTime方法返回毫秒数,自然就可以直接构建java.util.Date d = new java.util.Date(sqlDate.getTime());java.util.Date 是 java.sql.Date 的父类(

2013-04-08 10:48:52 484

原创 Spring JDBC Support with jdbc configuration in code directly

Pre:Create schema:vicky_schema;1.Create two tables;CREATE TABLE CONTACT (ID INT NOT NULL AUTO_INCREMENT, FIRST_NAME VARCHAR(60) NOT NULL, LAST_NAME VARCHAR(40) NOT NULL, BIRTH_DATE DATE,

2013-04-08 10:46:02 1116

原创 Log4j example

Source Code:package com.feifan.logging.log4j.ch2;import org.apache.log4j.Logger;public class FileBasedLoggingDemo implements Runnable{private static Logger logger =Logger.getLogger(FileB

2013-04-08 09:51:10 684

原创 Spring 关键字

控制反转 IoC --Inversion of Control面向方面编程AOP --Aspect-Oriented ProgrammingSSH --Spring+Structs+Hibernate

2012-11-13 17:17:53 300

原创 Java 常用的MIME 类型

Java 常用的MIME 类型text/htmlapplication/pdfvideo/quicktimeapplication/javaimage/jpegapplication/jarapplication/octet-streamapplication/x-zip

2012-11-07 13:45:38 716

原创 Servlet生命周期

Servlet生命周期Servlet加载类-->调用构造函数-->init()-->service() doGet/doPost-->destroy()

2012-11-07 13:30:56 229

原创 Java-What is the difference between <? super E> and <? extends E>?

What is the difference between <? super E> and <? extends E>?The first says that it's "some type which is an ancestor of E"; the second says that it's "some type which is a subclass of E". (In

2012-10-29 10:40:31 376

原创 Java-assert code

import java.util.Scanner;class AssertDemo {public static void main(String[] args) {Scanner scanner = new Scanner( System.in );int value = scanner.nextInt();assert ( value >= 0 && value

2012-10-26 11:10:02 214

原创 Java-Clone改写

public class CloneDemo  {public static void main(String[] args) {Shirt t = new Shirt();Person p1 = new Person("vicky","fan");Person p2 = (Person)p1.clone();System.out.println(p1);p1.shir

2012-10-25 16:47:59 191

原创 Java-改写equals 必须改写hashChode()

class H {private int x;private int y;private float z;private double t;H(int x, int y,float z, double t) {this.x = x;this.y = y;this.z = z;this.t = t;}public boolean equals(Ob

2012-10-25 16:47:17 307

原创 Java-改写equals方法必须遵循的准则

1.自反性 x.equals(x) 总是返回true;2.对称性 x.equals(y) == y.equals(x)3.传递性x.equals(y), y.equals(z),则x.equals(z)4,一致性 如果x.equals(y) == true,则总有x,equals(y) == true; 如果x.equals(y) == false,则总有x,equals(y) ==

2012-10-25 10:45:07 388

原创 Java 初始化值

1.byte ---- 0;2.short ---0;3.int -------0;4.long --- 0L;5.char ---- "\u0000" 空字符6.float ---- 0;7.double ---0;8.boolean --- false;9.引用 ---- null===================================

2012-10-24 11:12:04 268

原创 maven configuration

1.download mavenhttp://www.apache.org/dyn/closer.cgi/maven/binaries/maven-2.0.7-bin.tar.gz then unpack it to D:\apache-maven-3.0.4-bin2.配置maven, 将maven/bin目录设置到windows环境变量Path中3.检查maven是否安装成功, 在

2012-09-14 16:28:27 5153 2

原创 JDK环境变量配置

JAVA_HOME,JAVA_HOME指明JDK安装路径,就是刚才安装时所选择的路径D:/java/jdk1.5.0_08,此路径下包括lib,bin,jre等文件夹(此变量最好设置,因为以后运行tomcat,eclipse等都需要依*此变量)PATH,Path使得系统可以在任何路径下识别java命令,设为:%JAVA_HOME%/bin;%JAVA_HOME%/jre

2012-08-27 09:51:43 264

原创 Windows programming

1.许多Windows程序中的变量名使用一种称作「匈牙利表示法」的命名系统,该系统在变量名称前面增加了表示变量数据型态的短前缀现在仅需记住前缀i表示int、sz表示「以零结束的字符串」。int WINAPI WinMain (HINSTANCE hInstance, HINSTANCE hPrevInstance, PSTR szCmdLine, int iCmdShow)2.经

2012-07-25 17:23:05 258

原创 [Resolved] 1>MSVCRTD.lib(crtexe.obj) : error LNK2019

1>MSVCRTD.lib(crtexe.obj) : error LNK2019: unresolved external symbol _main referenced in function ___tmainCRTStartup1>D:\C++ Primer\OpenIE\Debug\OpenIE.exe : fatal error LNK1120: 1 unresolved exter

2012-07-25 10:36:20 333

COLORScrollBar

OLORS1在显示区域的左半部显示三种滚动条,并分别标以「Red」、「 Green」和「Blue」。当您挪动滚动条时,显示区域的右半部将变为三种原色混合而成的合成色,三种原色的数值显示在三个滚动条的下面。

2009-06-29

空空如也

TA创建的收藏夹 TA关注的收藏夹

TA关注的人

提示
确定要删除当前文章?
取消 删除