it.m2.net.telnet
Class SampleOptionHandler

java.lang.Object
  extended by it.m2.net.telnet.SampleOptionHandler

public class SampleOptionHandler
extends java.lang.Object


Constructor Summary
SampleOptionHandler()
           
 
Method Summary
 boolean acceptDo(int option)
           
 boolean acceptDont(int option)
           
 boolean acceptWill(int option)
           
 boolean acceptWont(int option)
           
 void sb(Telnet telnet, int option, int sbLength, byte[] sbBuffer)
          Invoke when telnet sub negotiation is necessary
 void setDo(Telnet telnet, int option, boolean oldState, boolean newState)
          Invoked when the option chane state
 void setWill(Telnet telnet, int option, boolean oldState, boolean newState)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

SampleOptionHandler

public SampleOptionHandler()
Method Detail

setDo

public void setDo(Telnet telnet,
                  int option,
                  boolean oldState,
                  boolean newState)
Invoked when the option chane state

Parameters:
telnet - Telnet ownner
option - Telnet option number
oldState - Old state of the option
newState - New state of the option

setWill

public void setWill(Telnet telnet,
                    int option,
                    boolean oldState,
                    boolean newState)

sb

public void sb(Telnet telnet,
               int option,
               int sbLength,
               byte[] sbBuffer)
        throws java.io.IOException
Invoke when telnet sub negotiation is necessary

Parameters:
telnet - Telnet ownner
option - Telnet option number
sbLength - lenght of the sub option received
sbBuffer - buffer with the sub option received.
Throws:
java.io.IOException

acceptDo

public boolean acceptDo(int option)

acceptWill

public boolean acceptWill(int option)

acceptWont

public boolean acceptWont(int option)

acceptDont

public boolean acceptDont(int option)


Copyright © 2003 MBARI.

The Monterey Bay Aquarium Research Institute (MBARI) provides this documentation and code "as is", with no warranty, express or implied, of its quality or consistency. It is provided without support and without obligation on the part of MBARI to assist in its use, correction, modification, or enhancement.