Skip to content

Instantly share code, notes, and snippets.

View kenti-lan's full-sized avatar

RockyLarm kenti-lan

View GitHub Profile
@safeJar
safeJar / mybatis
Created September 21, 2015 01:48
mybatis 和 spring 整合的基本配置
/**
1.导入相应的jar包
2.在applicationContext.xml文件中配置相应的bean
3.配置mybatis的配置文件
*/
这段主要是applicationContext.xml的配置
<!-- datasource -->
<bean id="dataSource" class="org.apache.commons.dbcp.BasicDataSource"
destroy-method="close">
<property name="driverClassName" value="${driverClassName}" />
@bryanjswift
bryanjswift / UAgentInfo.java
Created March 1, 2010 09:43
User Agent detection in Java
/* *******************************************
// LICENSE INFORMATION
// The code, "Detecting Smartphones Using PHP"
// by Anthony Hand, is licensed under a Creative Commons
// Attribution 3.0 United States License.
//
// Updated 01 March 2010 by Bryan J Swift
// - Remove un-needed if statements instead just returning the boolean
// inside the if clause
//