SpringFramework
文章平均质量分 87
davyjones2010
生活在这个世界而不知其义,如同徜徉于一座伟大的图书馆而不碰书籍。
展开
-
Spring 3.0: A Mocking Example for Explaining Basic Spring IoC Mechanism
1. Beanspackage beans;public class User{ private String username; private String password; public User() { } public User(String username, String password) { this.username...原创 2013-04-15 23:28:26 · 97 阅读 · 0 评论 -
Spring Batch: Intro II -- Read-Write-Process for Derby
1. In the following example, we will read data from multiple csv files and then write to Derby DB. 1) In order to read from multiple csv, we need "org.springframework.batch.item.file.MultiResou...原创 2014-06-20 14:53:39 · 162 阅读 · 0 评论 -
Spring Batch: Intro I -- Tasklet & Read-Process-Write example
1. Intro to Spring Batch 1) Spring Batch is a framework for Batch Processing - Execution of a series of Jobs. 2) Each "Job" contains many "Steps". And one "Step" can be a single "tasklet" ...原创 2014-06-20 14:33:32 · 279 阅读 · 0 评论 -
Spring JDBC: Introduction to JdbcTemplate (IV)--Batch Operations
1. As we know, it is meaningless to execute batch query. There is only batchUpdate provided in JdbcTemplate./** * @param sql defining an array of SQL statements that will be executed. */...原创 2013-12-21 20:24:34 · 170 阅读 · 0 评论 -
Spring JDBC: Introduction to JdbcTemplate (III)--JdbcTemplate Derivatives
1. JdbcDaoSupportpublic abstract class JdbcDaoSupport extends DaoSupport { private JdbcTemplate jdbcTemplate; public final void setDataSource(DataSource dataSource) { if (this.jdbcTemplate ...原创 2013-12-21 18:07:00 · 189 阅读 · 0 评论 -
Spring JDBC: Introduction to JdbcTemplate (II)--API Usage
1. queryForMappublic Map<String, Object> queryForMap(String sql);public Map<String, Object> queryForMap(String sql, Object... args);public Map<String, Object> queryForMap(Str...原创 2013-12-20 23:11:39 · 252 阅读 · 0 评论 -
Spring JDBC: Introduction to JdbcTemplate (I)
1. Why do we need jdbc template as we already have plain JDBC?1) Exception Handling2) Opening & Closing Connections3) Transaction HandlingOperation listed above are cumbersome and repeat...原创 2013-12-18 22:43:36 · 138 阅读 · 0 评论 -
Spring3: Dependency Configuration In Detail(Part II)
Introduction: In this article, we focus on the configuration file beans.xml for IoC purpose. Focusing on initialize beans whose property are collection types. Including <list/&g...原创 2013-04-17 15:29:12 · 98 阅读 · 0 评论 -
Spring3: Dependency Configuration In Detail(Part I)
Introduction: In this article, we focus on the configuration file beans.xml for IoC purpose. 1. A simple bean injected with simple property<?xml version="1.0" encoding="UTF-8"?><...原创 2013-04-17 14:25:56 · 117 阅读 · 0 评论 -
Spring3: How to set up dependency jars for basic IoC function
1. Import relevant jars for basic IoC purpose 1) Download spring-framework-3.2.2.RELEASE-dist.zip from http://www.springsource.org/download/community 2) Open eclipse and set up use...原创 2013-04-17 12:32:23 · 119 阅读 · 0 评论 -
Guice Webapp Insight
guice web dataflow:Basic Design Concept: 1) HttpRequest/HttpResponse will always be created by WebContainer(jetty/tomcat) and Guice will reuse/wrap them. 2) For Servlet that match the url pa...原创 2015-07-01 19:29:06 · 184 阅读 · 0 评论