org.apache.commons.net.telnet
Class TelnetTestResponder

java.lang.Object
  extended by org.apache.commons.net.telnet.TelnetTestResponder
All Implemented Interfaces:
Runnable

public class TelnetTestResponder
extends Object
implements Runnable

Simple stream responder. Waits for strings on an input stream and answers sending corresponfing strings on an output stream. The reader runs in a separate thread.

Author:
Bruno D'Avanzo

Constructor Summary
TelnetTestResponder(InputStream is, OutputStream os, String[] inputs, String[] outputs, long timeout)
          Constructor.
 
Method Summary
 void run()
          Runs the responder
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

TelnetTestResponder

public TelnetTestResponder(InputStream is,
                           OutputStream os,
                           String[] inputs,
                           String[] outputs,
                           long timeout)
Constructor. Starts a new thread for the reader.

Parameters:
is - - InputStream on which to read.
os - - OutputStream on which to answer.
inputs - - Array of waited for Strings.
inputs - - Array of answers.
Method Detail

run

public void run()
Runs the responder

Specified by:
run in interface Runnable


Copyright © 1997-2011 Apache Software Foundation. All Rights Reserved.