read a line from socket

i am new in java and also new in network programming in java..

i would like to read aline from socket, for that i had written the code just like below

ServerSocket serverSocket

..........................................

clientSocket = serverSocket.accept();

DataInputStream is = clientSocket.getInputStream();

..................................................

String take=is.readLine();

i got an error the method readLine() is not..

[491 byte] By [Manomohan.M.Ka] at [2007-11-27 3:49:44]
# 1
> i got an error the method readLine() is not.. is not what?And also, did you even bother to read DataInputStream's documentation to see what it's useful for? If not, go and do it. And while you're at it, also look at InputStreamReaders/BufferedReaders.
CeciNEstPasUnProgrammeura at 2007-7-12 8:53:38 > top of Java-index,Java Essentials,Java Programming...