반응형 형변환2 자바 int>String, String > int 형 변환하기 자바에서 int를 String으로, String을 int로 형 변환 시키는 일은 빈번한 일이지만,,,맨날 까먹는 나를위해서...남겨 놓는다.. String->int String str = Integer.parseInt(int); int->String int int = String.valueOf(str); 2018. 8. 31. [공통제작시] 공통코드로 쓸만한것 STRING 유틸 1. String객체가 Null이면 지정값으로 반환한다. /** * String객체가 Null이면 지정값으로 반환한다. * * @paramString형 객체 * @return변환 객체 * @see */public static String replaceNull( String value, String convValue ) {String rslt = value;if( rslt == null || rslt.trim().length() == 0 ) rslt = convValue;return rslt;}public static String replaceNull( Object value, String convValue ) {Object rslt = value;if( rslt == null) rslt.. 2018. 8. 17. 이전 1 다음 반응형