- 博客(8)
- 资源 (8)
- 问答 (1)
- 收藏
- 关注
转载 java程序性能优化
一、避免在循环条件中使用复杂表达式在不做编译优化的情况下,在循环中,循环条件会被反复计算,如果不使用复杂表达式,而使循环条件值不变的话,程序将会运行的更快。 例子: import java.util.vector;class cel { void method (vector vector) { for (int i = 0; i < vect
2012-09-26 21:34:51 1123
转载 hibernate Restrictions用法 MatchMode.ANYWHERE
from:http://hi.baidu.com/gebitan505/item/b40dd54b28553209e9350418 方法说明Restrictions.eq=Restrictions.allEq利用Map来进行多个等于的限制Restrictions.gt>Restrictions.ge>=Restrictions.lt<Re
2012-09-23 16:15:23 547
原创 spring+quartz定时任务
导入spring quartz jar包配置: com.Task 0 0 1 * * ? * com.Task类;public class fenboSchedule extends QuartzJobBean { pr
2012-09-13 19:58:46 782
转载 hibernate的findByExample
from http://blog.csdn.net/c1005351789/article/details/7008222;用了这么长时间的hibernate/spring,如果不是今天用的findByExample方法到现在还不知道findByExample的机制。惭愧Class User{ String username; String password =
2012-09-11 21:45:44 2611
转载 Hibernate的merge与update方法的区别
今天做了个测试,写了个测试用例来看看merge与update时控制台打印出来的日志有什么不一样。实体bean很简单,就id和name两个字段,接下来分别给出以下几种测试情形的控制台日志内容:1. 数据库记录已存在,更改person的name为一个新的name。 merge方法打印出的日志如下: Hibernate: select person0_.id as id0_0_,
2012-09-11 21:31:50 545
原创 mysql重复插入
long id1 = 3; long id2 = 3; Connection conn = null; try { Class.forName("com.mysql.jdbc.Driver"); conn = DriverManager .getConnection("jdbc:mysql://localhost/test?user=root&pass
2012-09-07 19:20:59 733
原创 xuggle学习-IContainer2
通过IContainer主要可以获取视频/音频文件的相关信息以及音视频信息,如起始时间,时常,比特率等等。 public static void main(String[] args) { String filename = "c:/0824.flv"; // Create a Xuggler container object IContainer cont
2012-09-05 20:32:10 2960 2
原创 xuggle学习-IContainer
IContainer可用于本地视频流或网络视频的读取。基本用法如官方:IContainer container = IContainer.make();if (container.open("myfile.flv", IContainer.Type.READ, null) <0) throw new RuntimeException("failed to open"); int n
2012-09-04 18:42:15 4937
apache-ant
2010-06-04
flex加载module问题
2011-05-13
TA创建的收藏夹 TA关注的收藏夹
TA关注的人