Control amount of data retrieved - java.io

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • brendanmcdonagh
    New Member
    • Nov 2007
    • 153

    Control amount of data retrieved - java.io

    Hi all,

    I've come up with an idea but I'm struggling with the implementation!

    My network thread contacts my server and presents some variables for a search of a web service. Now, the page i call at my server prints out the results for my inputstream to read. It works ok but sometimes there might be 300 results so i want to somehow retrieve only 4 results at a time and then pause the thread.

    I'm then going to put a listener on the fourth row of my table to unpause the thread and retrieve another 4 results. I'm ok with this part.

    Currently I just use in.read(length) but obviously this isn't sufficient for my new challenge, i haven't made it that tough to do this i don't think as their is only one result per line so somehow i need to find a method that will read for 4 lines, update display and then pause.

    Is this possible and could someone help me please? Where do i start?

    Regards

    Brendan
  • RedSon
    Recognized Expert Expert
    • Jan 2007
    • 4980

    #2
    Moved from Mobile dev.

    Brendan, you might find better help posting in the general java forum instead of the mobile forum.

    Comment

    Working...