本文介绍在Java执行Python脚本3种方法,使用Java实现的Python解析器Jython,使用Runtime运行Shell命令,使用ProcessBuilder创建操作系统进程。
Program Language
Calculate connected dominating sets (CDS)
It is believed that the minimum connected dominating set problem cannot be solved in polynomial time. To the best of my knowledge, there is no source code available for approximation algorithms. Therefore, I decide to implement one proposed by M. Rai in 2009.
Java Application Notes: HashMap
Collect common operations in HashMap
, including iteration, sorting.
Java data type conversion among int, Integer and String
This blog presents how to convert data types among int, Integer and String.
Java集合框架:Comparator
最近编写Comparator经常抛出异常,促使我较深入学习下Java的Comparator。本文介绍。。。
Java求集合的交集、并集、差集(必要时重写equals和hashCode方法)
Java求集合的交集、差集、并集,必要时需要重写equals或/且hashCode方法,本文给出应用实例,并自行编写函数将求得的交、差、并集存储在新的集合,不破坏原集合的内容。
阅读JDK源码:Eclipse+ObjectAid UML Explorer(生成UML图)
最近在学习Java集合框架,就想着,生成JDK源码的UML图,从而有个框架性认识。本文介绍如何在Eclipse下阅读JDK源码,并利用Eclipse插件ObjectAid UML Explorer生成UML图。 Read more