Primitive Type의 Data가 필요하면 -> parseInt() 사용 -> int, long, short

Reference Type의 Class 객체가 필요하면 -> valueOf() 사용 -> Integer, Long, Short, String

 

 

soobarkbar.tistory.com/57

 

문자열 (String) 형변환 : Casting, valueOf, toString

valueOf (Object obj) Returns the string representation of the Object argument. (Java docs) if the argument is null, then a string equal to "null"; otherwise, the value of obj.toString() is retu..

soobarkbar.tistory.com

+ Recent posts