fixed sonar rule violations

This commit is contained in:
wenshao
2012-08-29 08:41:29 +08:00
parent 69103eeffc
commit fe50086568
15 changed files with 157 additions and 54 deletions
@@ -61,9 +61,14 @@ public class StringUtils {
* @return
*/
public static Integer stringToInteger(String in) {
if (in == null) return null;
if (in == null) {
return null;
}
in = in.trim();
if (in.length() == 0) return null;
if (in.length() == 0) {
return null;
}
try {
return Integer.parseInt(in);
} catch (NumberFormatException e) {