1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16 package org.apache.commons.net.telnet;
17
18 /***
19 * Implements the telnet suppress go ahead option RFC 858.
20 * <p>
21 * @author Bruno D'Avanzo
22 ***/
23 public class SuppressGAOptionHandler extends TelnetOptionHandler
24 {
25 /***
26 * Constructor for the SuppressGAOptionHandler. Allows defining desired
27 * initial setting for local/remote activation of this option and
28 * behaviour in case a local/remote activation request for this
29 * option is received.
30 * <p>
31 * @param initlocal - if set to true, a WILL is sent upon connection.
32 * @param initremote - if set to true, a DO is sent upon connection.
33 * @param acceptlocal - if set to true, any DO request is accepted.
34 * @param acceptremote - if set to true, any WILL request is accepted.
35 ***/
36 public SuppressGAOptionHandler(boolean initlocal, boolean initremote,
37 boolean acceptlocal, boolean acceptremote)
38 {
39 super(TelnetOption.SUPPRESS_GO_AHEAD, initlocal, initremote,
40 acceptlocal, acceptremote);
41 }
42
43 /***
44 * Constructor for the SuppressGAOptionHandler. Initial and accept
45 * behaviour flags are set to false
46 ***/
47 public SuppressGAOptionHandler()
48 {
49 super(TelnetOption.SUPPRESS_GO_AHEAD, false, false, false, false);
50 }
51
52 /***
53 * Implements the abstract method of TelnetOptionHandler.
54 * <p>
55 * @param suboptionData - the sequence received, whithout IAC SB & IAC SE
56 * @param suboptionLength - the length of data in suboption_data
57 * <p>
58 * @return always null (no response to subnegotiation)
59 ***/
60 public int[] answerSubnegotiation(int suboptionData[], int suboptionLength)
61 {
62 return null;
63 }
64
65 /***
66 * Implements the abstract method of TelnetOptionHandler.
67 * <p>
68 * @return always null (no response to subnegotiation)
69 ***/
70 public int[] startSubnegotiationLocal()
71 {
72 return null;
73 }
74
75 /***
76 * Implements the abstract method of TelnetOptionHandler.
77 * <p>
78 * @return always null (no response to subnegotiation)
79 ***/
80 public int[] startSubnegotiationRemote()
81 {
82 return null;
83 }
84 }