Skip to content

Commit

Permalink
fix the bug
Browse files Browse the repository at this point in the history
  • Loading branch information
chenssy89 committed Aug 21, 2015
1 parent eda0c84 commit e3015e1
Show file tree
Hide file tree
Showing 11 changed files with 30 additions and 31 deletions.
12 changes: 6 additions & 6 deletions src/com/JUtils/base/BigDecimalUtils.java
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
* 提供精确的加减乘除运算
* @Project:JUtils
* @file:BigDecimalUtils.java
* @Authro:chenming
* @Authro:chenssy
* @data:2014年9月15日
*/
public class BigDecimalUtils {
Expand All @@ -24,7 +24,7 @@ public class BigDecimalUtils {
/**
*
* 加法运算
* @autor:chenming
* @autor:chenssy
* @data:2014年9月15日
*
* @param v1
Expand All @@ -40,7 +40,7 @@ public static String add(String v1,String v2){
/**
* 除法运算<br>
* 当发生除不尽的情况时,由scale参数指定精度,以后的数字四舍五入。
* @autor:chenming
* @autor:chenssy
* @data:2014年9月15日
*
* @param v1
Expand Down Expand Up @@ -75,7 +75,7 @@ public static String div(String v1,String v2,int scale,int round){
* v1 > v2 return 1<br>
* v1 = v2 return 0<br>
* v1 < v2 return -1
* @autor:chenming
* @autor:chenssy
* @data:2014年9月15日
*
* @param v1
Expand All @@ -92,7 +92,7 @@ public static int compareTo(String v1,String v2){

/**
* 返回较小数
* @autor:chenming
* @autor:chenssy
* @data:2014年9月15日
*
* @param v1
Expand All @@ -107,7 +107,7 @@ public static String returnMin(String v1,String v2){

/**
* 返回较大数
* @autor:chenming
* @autor:chenssy
* @data:2014年9月15日
*
* @param v1
Expand Down
6 changes: 3 additions & 3 deletions src/com/JUtils/base/DateUtils.java
Original file line number Diff line number Diff line change
Expand Up @@ -777,7 +777,7 @@ else if(type == 3){
* 若date1 > date2 则返回 1<br>
* 若date1 = date2 则返回 0<br>
* 若date1 < date2 则返回-1
* @autor:chenming
* @autor:chenssy
* @data:2014年9月9日
*
* @param date1
Expand Down Expand Up @@ -806,7 +806,7 @@ public static int compare(String date1, String date2,String format) {
/**
* 将String 转换为 timestamp<br>
* 注:value必须形如: yyyy-mm-dd hh:mm:ss[.f...] 这样的格式,中括号表示可选,否则报错!!!
* @autor:chenming
* @autor:chenssy
* @data:2014年9月22日
*
* @param value
Expand All @@ -822,7 +822,7 @@ public static Timestamp string2Timestamp(String value) throws Exception{

/**
* 将timeStamp 转换为String类型,format为null则使用默认格式 yyyy-MM-dd HH:mm:ss
* @autor:chenming
* @autor:chenssy
* @data:2014年9月22日
*
* @param value
Expand Down
8 changes: 4 additions & 4 deletions src/com/JUtils/base/MoneyUtils.java
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ public class MoneyUtils {
/**
* 特殊字符:整
*/
private static final String CN_FULL = "";
private static final String CN_FULL = "";

/**
* 特殊字符:负
Expand All @@ -35,7 +35,7 @@ public class MoneyUtils {
/**
* 零元整
*/
private static final String CN_ZEOR_FULL = "零元" + CN_FULL;
private static final String CN_ZEOR_FULL = "零元整";

/**
* 金额的精度,默认值为2
Expand All @@ -44,11 +44,11 @@ public class MoneyUtils {

/**
* 人民币转换为大写,格式为:x万x千x百x十x元x角x分
*
* @autor:chenssy
* @data:2014年8月7日
*
* @param numberOfMoney
* 传入的金额
* @param numberOfMoney 传入的金额
* @return
*/
public static String number2CNMontray(String numberOfMoney) {
Expand Down
12 changes: 6 additions & 6 deletions src/com/JUtils/base/RandomUtils.java
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
* 随机数工具类
* @Project:JUtils
* @file:RandomUtils.java
* @Authro:chenming
* @Authro:chenssy
* @data:2014年8月11日
*/
public class RandomUtils {
Expand All @@ -16,7 +16,7 @@ public class RandomUtils {

/**
* 获取定长的随机数,包含大小写、数字
* @autor:chenming
* @autor:chenssy
* @data:2014年8月11日
*
* @param length
Expand All @@ -34,7 +34,7 @@ public static String generateString(int length) {

/**
* 获取定长的随机数,包含大小写字母
* @autor:chenming
* @autor:chenssy
* @data:2014年8月11日
*
* @param length
Expand All @@ -52,7 +52,7 @@ public static String generateMixString(int length) {

/**
* 获取定长的随机数,只包含小写字母
* @autor:chenming
* @autor:chenssy
* @data:2014年8月11日
*
* @param length
Expand All @@ -65,7 +65,7 @@ public static String generateLowerString(int length) {

/**
* 获取定长的随机数,只包含大写字母
* @autor:chenming
* @autor:chenssy
* @data:2014年8月11日
*
* @param length
Expand All @@ -78,7 +78,7 @@ public static String generateUpperString(int length) {

/**
* 获取定长的随机数,只包含数字
* @autor:chenming
* @autor:chenssy
* @data:2014年8月11日
*
* @param length
Expand Down
2 changes: 1 addition & 1 deletion src/com/JUtils/base/StringUtils.java
Original file line number Diff line number Diff line change
Expand Up @@ -253,7 +253,7 @@ public static String subString(String resourceString,int length){

/**
*
* @autor:chenming
* @autor:chenssy
* @data:2014年8月10日
*
* @param htmlString
Expand Down
4 changes: 3 additions & 1 deletion src/com/JUtils/clone/CloneUtils.java
Original file line number Diff line number Diff line change
Expand Up @@ -63,11 +63,13 @@ public static <T extends Serializable> T cloneObject(T obj) {
public static <T> Collection<T> cloneCollection(Collection<T> collection) throws ClassNotFoundException, IOException{
ByteArrayOutputStream byteOut = new ByteArrayOutputStream();
ObjectOutputStream out = new ObjectOutputStream(byteOut);
out.writeObject(collection);
out.writeObject(collection);
out.close();

ByteArrayInputStream byteIn = new ByteArrayInputStream(byteOut.toByteArray());
ObjectInputStream in = new ObjectInputStream(byteIn);
Collection<T> dest = (Collection<T>) in.readObject();
in.close();

return dest;
}
Expand Down
2 changes: 1 addition & 1 deletion src/com/JUtils/excel/ExcelExportHelper.java
Original file line number Diff line number Diff line change
Expand Up @@ -217,7 +217,7 @@ public void exportExcelAndSave(String[] header,List<Object> excelList,String she
* header = ["学号","年龄","性别","班级"]<Br>
* properties = ["id","age","sex","class"],其对应的excelList中javaBean的属性值
*
* @author chenming
* @author chenssy
* @date 2014年6月19日 下午6:24:56
*
* @param header
Expand Down
7 changes: 2 additions & 5 deletions src/com/JUtils/file/FileUtils.java
Original file line number Diff line number Diff line change
Expand Up @@ -27,11 +27,8 @@ public class FileUtils {
*/
public static boolean isExist(String filePath,boolean isNew){
File file = new File(filePath);
if(!file.exists()){
if(isNew){
file.mkdirs(); //新建文件路径
}
return true;
if(!file.exists() && isNew){
return file.mkdirs(); //新建文件路径
}
return false;
}
Expand Down
2 changes: 1 addition & 1 deletion src/com/JUtils/image/ImageUtil.java
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@
* 对图片进行压缩、水印、伸缩变换、透明处理、格式转换操作
* @Project:JUtils
* @file:PictureUtil.java
* @Author:chenming
* @Author:chenssy
* @data:2015年3月19日
*/
public class ImageUtil {
Expand Down
4 changes: 2 additions & 2 deletions src/com/JUtils/jsp/JSPBeanUtils.java
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ public class JSPBeanUtils {

/**
* 获取时间戳(格式为:yyyyMMddHH24mmss)
* @autor:chenming
* @autor:chenssy
* @data:2014年8月6日
*
* @return
Expand All @@ -24,7 +24,7 @@ public static String getTimeStamp(){

/**
* 根据指定格式获取当前时间
* @autor:chenming
* @autor:chenssy
* @data:2014年8月7日
*
* @param format
Expand Down
2 changes: 1 addition & 1 deletion src/com/JUtils/word/WordExportUtils.java
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
* 需要对Word中的图片、样式、文字、表格进行处理,同时由于POI对Word的处理能力有限,所以采用Jadoc处理
* @Project:JUtils
* @file:WordExportUtils.java
* @Authro:chenming
* @Authro:chenssy
* @data:2014年8月10日
*/
public class WordExportUtils {
Expand Down

0 comments on commit e3015e1

Please sign in to comment.