I'm confused with primitive types in Java and the methods of converting one type to another. If, say, I have an integer and I want to convert it to a string, I need to use a static method of Integer or String, e.g.
String.valueOf(some_integer); But if I want to convert a stirng to a char array I can use something like,
some_string.toCharArray(); My question is why? Why do I need to use a static method for the first one?