一、关键的通用类public class PoiExportUtils { private static HSSFWorkbook workBook; public PoiExportUtils(){ workBook = new HSSFWorkbook(); } /** * 创建sheet *....
分类:
其他好文 时间:
2015-04-28 22:14:50
阅读次数:
236
1 public class Test { 2 private static int sum=1; 3 private static void giveBirth(int year) 4 { 5 if(year>3) 6 sum+=y...
分类:
其他好文 时间:
2015-04-28 20:55:09
阅读次数:
122
有时我们需要在程序执行进程中遇到一些异常,需要收集一logcat的信息,android下就可以使用以下方法获取:private static String getLogcatInfo(){ String strLogcatInfo = ""; try{ ...
分类:
移动开发 时间:
2015-04-28 13:44:01
阅读次数:
143
逻辑标签public class IndexAction extends BasicAction{ private static final long serialVersionUID = 1L; private String name; p...
分类:
其他好文 时间:
2015-04-28 11:35:57
阅读次数:
142
public class ActivityAction extends CoreAction { private static final Logger log = Logger.getLogger(ActivityAction.class); @Autowired private Activi.....
分类:
编程语言 时间:
2015-04-28 08:14:53
阅读次数:
206
public class TestHive {
private static String driverName = "org.apache.hadoop.hive.jdbc.HiveDriver";
public static void main(String[] args) throws SQLException {
try {
Class.forName(driverNam...
分类:
数据库 时间:
2015-04-27 10:07:08
阅读次数:
156
class Solution {private: static int compare(const void * a, const void * b) { return (*(int*)a - *(int*)b); }public:int majorityElemen...
分类:
编程语言 时间:
2015-04-25 19:39:25
阅读次数:
142
public class Arith {
/**
* 由于Java的简单类型不能够精确的对浮点数进行运算,这个工具类提供精 确的浮点数运算,包括加减乘除和四舍五入。
*/
// 默认除法运算精度
private static final int DEF_DIV_SCALE = 10;
// 这个类不能实例化
private Arith() {
}
/**
* 提供精确...
分类:
编程语言 时间:
2015-04-25 18:23:46
阅读次数:
128
private static Dictionary seatDic = new Dictionary{
{"硬座","1"},{"无座","1"},{"软座","1"},{"硬卧","3"},{"软卧","4"},{"高级软卧","1"},{"一等座","M"},{"二等座","O"},{"特等座","P"},{"商务座","9"}
};...
分类:
其他好文 时间:
2015-04-25 18:22:41
阅读次数:
130
1 private static Complex[] FFT1(Complex[] f) 2 { 3 int N=f.length; 4 int power= (int) (Math.log10(N)/Math.log10(2)); 5 ...
分类:
其他好文 时间:
2015-04-25 16:37:42
阅读次数:
130