2020-01-28 18:58:44 +01:00
|
|
|
package envoy.event;
|
|
|
|
|
|
|
|
/**
|
|
|
|
* Signifies to the client that the handshake failed for the attached
|
|
|
|
* reason.<br>
|
|
|
|
* <br>
|
|
|
|
* Project: <strong>envoy-common</strong><br>
|
|
|
|
* File: <strong>HandshakeRejectionEvent.java</strong><br>
|
|
|
|
* Created: <strong>28 Jan 2020</strong><br>
|
|
|
|
*
|
|
|
|
* @author Kai S. K. Engelbart
|
|
|
|
* @since Envoy Common v0.3-alpha
|
|
|
|
*/
|
2020-02-11 16:53:41 +01:00
|
|
|
public class HandshakeRejectionEvent extends Event<String> {
|
2020-01-28 18:58:44 +01:00
|
|
|
|
2020-02-07 23:29:22 +01:00
|
|
|
/**
|
2020-04-10 15:42:00 +02:00
|
|
|
* Select this value if a given password hash or user was incorrect.
|
2020-02-08 09:17:11 +01:00
|
|
|
*/
|
2020-04-10 15:42:00 +02:00
|
|
|
public static final String WRONG_PASSWORD_OR_USER = "password or user were entered incorrectly";
|
2020-02-08 09:17:11 +01:00
|
|
|
|
2020-02-07 23:29:22 +01:00
|
|
|
/**
|
2020-04-10 15:42:00 +02:00
|
|
|
* Select this value if the handshake could not be completed for some reason.
|
2020-02-07 23:29:22 +01:00
|
|
|
*/
|
2020-04-10 15:42:00 +02:00
|
|
|
public static final String INTERNAL_ERROR = "the process could not be finished as an internal error occurred";
|
2020-02-07 23:29:22 +01:00
|
|
|
|
2020-03-24 19:06:56 +01:00
|
|
|
private static final long serialVersionUID = 0L;
|
2020-01-28 18:58:44 +01:00
|
|
|
|
|
|
|
/**
|
|
|
|
* Creates an instance of {@link HandshakeRejectionEvent} with an empty reason.
|
|
|
|
*
|
|
|
|
* @since Envoy Common v0.3-alpha
|
|
|
|
*/
|
2020-02-11 16:53:41 +01:00
|
|
|
public HandshakeRejectionEvent() { super(""); }
|
2020-01-28 18:58:44 +01:00
|
|
|
|
|
|
|
/**
|
|
|
|
* Creates an instance of {@link HandshakeRejectionEvent}.
|
|
|
|
*
|
|
|
|
* @param reason the reason why the handshake was rejected
|
|
|
|
* @since Envoy Common v0.3-alpha
|
|
|
|
*/
|
2020-02-12 05:58:40 +01:00
|
|
|
public HandshakeRejectionEvent(String reason) { super(reason); }
|
2020-01-28 18:58:44 +01:00
|
|
|
}
|