java - Read single line from FTP server without downloading whole file using it.sauronsoftware.ftp4j.FTPClient -


how can read single line ftp server without downloading whole file using it.sauronsoftware.ftp4j.ftpclient.

now, downloading whole file , reading first line of file, there way can read first line of file without download file in local machine. should use it.sauronsoftware.ftp4j

@http://www.sauronsoftware.it/projects/ftp4j/manual.php

note : should use it.sauronsoftware.ftp4j.ftpclient , not apache.

mohit,

use socket dtconnection; dtconnection.getinputstream(); of ftp4j.ftpclient inputstream, using inputstream can read first line of.

you can find below example hoe read first line using inputstream

bufferedreader bufferedreader = null; string firstline = null;

bufferedreader = new bufferedreader(new inputstreamreader(this.datatransferinputstream, "utf-8")); firstline = bufferedreader.readline();

hope solution work you.


Comments

Popular posts from this blog

php - Wordpress website dashboard page or post editor content is not showing but front end data is showing properly -

javascript - Get parameter of GET request -

javascript - Twitter Bootstrap - how to add some more margin between tooltip popup and element -