package com.jscape.inet.ssh.protocol.v2.messages;

import com.jscape.inet.ssh.protocol.messages.Message;
import com.jscape.util.net.connection.MessageConnection;

/**
 * @author Alex Usun
 */
public class SshMsgKexDhGexRequestOld
        extends Message<SshMsgKexDhGexRequestOld.Handler> {

    public final int n;

    public SshMsgKexDhGexRequestOld(int n) {
        this.n = n;
    }

    @Override
    public Class handlerClass() {
        return Handler.class;
    }

    @Override
    public void accept(Handler handler, MessageConnection<Message> connection) {
        handler.handle(this, connection);
    }

    @Override
    public String toString() {
        return "SshMsgKexDhGexRequestOld {"
                + "n=" + this.n
                + '}';
    }

    public interface Handler
            extends Message.HandlerBase {

        void handle(SshMsgKexDhGexRequestOld message, MessageConnection<Message> connection);

    }
}
