php Webサーバーページからhttp応答を取得するために、以下に示すコーディングがあります。
public static void stopPHPDataChecker() {      
        canStop=true;
}
public static void main (String args[]) {
    // http request to the php page and get the response
    PHPDataChecker pdc = new PHPDataChecker();
    ScheduledExecutorService scheduler = Executors.newScheduledThreadPool(1);
    final ScheduledFuture<?> pdcHandle = scheduler.scheduleAtFixedRate(pdc, 0L, 10L, TimeUnit.MILLISECONDS);// Start schedule
    scheduler.schedule(new Runnable() {
        public void run() {
            System.out.println(">> TRY TO STOP!!!");
            pdcHandle.cancel(true);
            Sheduler.stopPHPDataChecker();
            System.out.println("DONE");
        }
    }, 1L, TimeUnit.MILLISECONDS);
   do {
        if (canStop) {
            scheduler.shutdown();
        }
    } while (!canStop);
    System.out.println("END");
}
このコーディングは1つの応答のみを返しますが、戻り値に応じてさまざまなタスクを実行できるように、応答を継続的に取得する必要があります。どうすればいいですか?前もって感謝します :)