I tried to collect the data from a socket. For that, I coded :
InputStream i = socket.getInputStream();
InputStreamReader rawAnswer= InputStreamReader(i);
But an error occured ( I use Eclipse as an IDE ) : " The method InputStreamReader(InputStream) is undefined". However, the documentation says that the constructor exists. I then tried to create an InputStreamReader from a FileInputStream and it worked perfectly. Am I missing anything ?