- 浏览: 468245 次
- 性别:
- 来自: 北京
文章分类
- 全部博客 (371)
- Java (44)
- Flex (25)
- Design Pattern / UML (5)
- JVM (14)
- Software Engineer (4)
- Testing (30)
- Web Backend (60)
- Linux (7)
- Database (11)
- SOA (28)
- English (6)
- FX (5)
- SAP Support (25)
- SAP Development (5)
- SAP Impl & Oprn (8)
- Articles (15)
- Music (4)
- Recipe (14)
- Multi-thread (4)
- Lucene (2)
- CS basic / Algorithm (12)
- Tour (3)
- C C++ (21)
- Others (10)
- Code Repository C++ (1)
- Code Repository Java (1)
- Code Repository Algorithm (1)
- Code Repository SQL (1)
- Web Frontend (4)
最新评论
-
xiangxm:
Java 强引用、 软引用、 弱引用、虚引用 -
nml-lyb:
123
Mule 的第一个例子 -
nml-lyb:
http://www.baidu.com
Mule 的第一个例子 -
white___ant:
...
Java 强引用、 软引用、 弱引用、虚引用 -
joeyon:
...
Java NIO介绍
1、计算时间
long StartTime = System.currentTimeMillis(); // 取出目前時間
// ==============================
// 你的程式
// ==============================
long ProcessTime = System.currentTimeMillis() - StartTime; // 計算處理時間
2、线程休眠
try {
Thread.sleep(500);
} catch (InterruptedException e) { }
3、生成随机数
int randomNumber=(int)(Math.random()*8)+1;
4、Runtime.getRuntime( ).exec( ) 的运用 (1)打开本地文件 public class OpenFile { public static void main(String[] args) { String path = "c:/temp/SW.txt"; try{ Runtime.getRuntime().exec("cmd /c start "+path); }catch(Exception e) { } } } (2)运行.bat文件 public class RunBat { public RunBat (String cmdline) { try{ Process p = Runtime.getRuntime().exec(cmdline); }catch(Exception e) { } } public static void main(String[] args) { new RunBat("c:/temp/test.bat"); } }
(3)运行exe 文件 public class OpenFile { public static void main(String[] args) { try{ Runtime.getRuntime().exec("c:/temp/WinRAR.exe"); }catch(Exception e){ } } }
5、HashMap 用法 private static final String FUND_KEY = "fund"; private static final String SUB_KEY = "subaccount"; HashMap resultMap = new HashMap(2); List mrFunds = new ArrayList(); List mrSubaccts = new ArrayList(); resultMap.put(FUND_KEY, mrFunds); resultMap.put(SUB_KEY, mrSubaccts); return resultMap; HashMap mrAccts = getSelectedChildrenForMRGroup(groups); List mrFunds = (List)mrAccts.get(FUND_KEY); List mrSubacctouns = (List)mrAccts.get(SUB_KEY); 6、Log public void save_old(AddClient addClient) { log.debug("execting AddClient"); try { getHibernateTemplate().save(addClient); log.debug("AddClient successful"); } catch (RuntimeException re) { log.error("AddClient failed", re); throw re; } }
发表评论
-
java8 Stream Lazy 解释 (非实现原理)
2015-07-22 07:49 1584http://blog.csdn.net/dm_vincen ... -
java8 系列2 深入理解Java 8 Lambda(类库篇——Streams API,Collectors和并行)
2015-07-22 07:00 2481http://zh.lucida.me/blog/java ... -
java8 系列1 深入理解Java 8 Lambda(语言篇——lambda,方法引用,目标类型和默认方法)
2015-07-22 06:58 1068http://zh.lucida.me/blog/java- ... -
Java 8 Stream探秘 具体实现
2015-07-22 06:31 896http://colobu.com/2014/11/18/J ... -
Arrays.asList() 的了解
2015-07-21 23:05 1172为什么Arrays.asList() 返回的list是 i ... -
java8 Lambda expressions
2015-07-14 13:09 879The single most important chan ... -
java8 new features
2015-07-08 02:06 701http://www.javacodegeeks.com/2 ... -
ReentrantLock与synchronized
2014-09-02 23:34 550http://uule.iteye.com/blog/148 ... -
PriorityQueue的使用
2014-05-29 12:14 962http://blog.csdn.net/yangzhon ... -
java的移位操作详解,左移和右移 << >>, 补码计算
2014-04-17 10:28 808---------------------补码--- ... -
深入Java集合学习系列:ArrayList的实现原理
2014-02-13 09:04 566http://zhangshixi.iteye.com/bl ... -
java集合类 ------------ 实现 细节
2014-02-12 23:12 534深入Java集合学习系列:ArrayList的 ... -
两种简单的方式快速实现hashCode 和 equals方法
2014-02-04 10:46 647http://hi.baidu.com/coolcat_p ... -
集合类 Set
2013-12-30 03:50 504http://www.cnblogs.com/yuchao ... -
java1.5新特性
2013-10-23 10:59 6711.自动包装和解包(Autoboxing and unboxi ... -
正则表达式30分钟入门教程
2013-10-22 00:21 543http://blog.csdn.net/cumt168/a ... -
总结Java方法(函数)传值和传引用的问题
2013-09-16 08:38 614http://java.chinaitlab.com/bas ... -
有状态,无状态对象是什么概念
2013-06-21 06:00 1129http://blog.csdn.net/showwair/ ... -
Dom4j的使用(全而好的文章)
2013-06-09 21:12 541http://xhy0422.iteye.com/blog/ ... -
serialVersionUID 用来表明类的不同版本间的兼容性
2013-06-03 23:12 816http://blog.csdn.net/hulefei29 ...
相关推荐
以上只是一部分可能包含在"Tricks of the Java Programming Gurus"中的知识点。这些技巧可以帮助开发者成为真正的Java编程大师,提升代码质量,降低维护成本。深入学习和实践这些技巧,将使你在Java开发道路上...
TRICKS OF THE JAVA™ PROGRAMMING GURUS
"Java Crash Course" contains a multitude of tips and tricks, examples and exercises you can do to grow your Java programming skills to unprecedented levels. We chose the content of this book carefully...
"Java Crash Course" contains a multitude of tips and tricks, examples and exercises you can do to grow your Java programming skills to unprecedented levels. We chose the content of this book carefully...
Write any Java program logic with strategies, tips, and tricks Leverage advanced topics in Java collections to solve Java-related problems Understand and use objects, classes, methods, and functions ...
英文经典原著 Java Reflection in Action Java Reflection in Action is unique in presenting a clear account of all the cool things you can do with reflection, and...author of Concurrent Programming in Java
As a teacher, has taken over 1,000 hours of training in basic Java, J2EE, and the Struts framework. As a researcher, he has worked in the field of information retrieval, developing applications for ...
- **《Java Tips and Tricks》**:该书通过一系列的小贴士和技术要点帮助读者解决常见问题,并掌握一些高效编程的方法。 - **O'Reilly 出版的《Java I/O》**:深入介绍了 Java 输入输出流的概念和使用方法,对于理解...
sometimes perplexing programming techniques along with enough background to understand how to extend and vary them. This book overcomes reflection’s reputation as a mysterious and esoteric philo- ...
Also, Extreme Programming (XP), Agile Model Driven Development (AMDD) and refactoring are methods that can expedite the software development projects by reducing the amount of up front requirements ...
Also, Extreme Programming (XP), Agile Model Driven Development (AMDD) and refactoring are methods that can expedite the software development projects by reducing the amount of up front requirements ...
This step-by-step guide has examples on every page and is filled with bonus tips and tricks to make your app stand out. If you follow this guide you will have a completed app in as little as one day. ...
Groovy in Action is a comprehensive guide to Groovy programming, introducing Java developers to the new dynamic features that Groovy provides. To bring you Groovy in Action, Manning again went to the...
并且有一本《Tricks of the Windows Game Programming Gurus》英文(或者中文)书籍正在阅读。 说明:当看到André Lamothe大师所著游戏编程书籍时非常兴奋。本人在学习《Tricks of the Windows Game Programming ...
Author Rod Stephens is a well-known programming authority and has written more than 25 programming books covering C#, Java, VB, and other languages. ☆ 出版信息:☆ [作者信息] Rod Stephens [出版...
This book is for anyone who wants to learn computer programming and knows absolutely nothing about it. Of course, if you are wondering whether this book is going to teach you how to create amazing ...
Author Rod Stephens is a well-known programming authority and has written more than 25 programming books covering C#, Java, VB, and other languages. His books have sold more than 60,000 copies in ...