// Generated by delombok at Tue Dec 16 19:35:27 UTC 2025
package net.md_5.bungee.api.event;

import net.md_5.bungee.api.Callback;
import net.md_5.bungee.api.config.ServerInfo;
import net.md_5.bungee.api.connection.ProxiedPlayer;

/**
 * Event called as soon as a connection has a {@link ProxiedPlayer} and is ready
 * to be connected to a server.
 */
public class PostLoginEvent extends AsyncEvent<PostLoginEvent> {
    /**
     * The player involved with this event.
     */
    private final ProxiedPlayer player;
    /**
     * The server to which the player will initially be connected.
     */
    private ServerInfo target;

    public PostLoginEvent(ProxiedPlayer player, ServerInfo target, Callback<PostLoginEvent> done) {
        super(done);
        this.player = player;
        this.target = target;
    }

    /**
     * The player involved with this event.
     */
    @java.lang.SuppressWarnings("all")
    @lombok.Generated
    public ProxiedPlayer getPlayer() {
        return this.player;
    }

    /**
     * The server to which the player will initially be connected.
     */
    @java.lang.SuppressWarnings("all")
    @lombok.Generated
    public ServerInfo getTarget() {
        return this.target;
    }

    /**
     * The server to which the player will initially be connected.
     */
    @java.lang.SuppressWarnings("all")
    @lombok.Generated
    public void setTarget(final ServerInfo target) {
        this.target = target;
    }

    @java.lang.Override
    @java.lang.SuppressWarnings("all")
    @lombok.Generated
    public java.lang.String toString() {
        return "PostLoginEvent(player=" + this.getPlayer() + ", target=" + this.getTarget() + ")";
    }

    @java.lang.Override
    @java.lang.SuppressWarnings("all")
    @lombok.Generated
    public boolean equals(final java.lang.Object o) {
        if (o == this) return true;
        if (!(o instanceof PostLoginEvent)) return false;
        final PostLoginEvent other = (PostLoginEvent) o;
        if (!other.canEqual((java.lang.Object) this)) return false;
        final java.lang.Object this$player = this.getPlayer();
        final java.lang.Object other$player = other.getPlayer();
        if (this$player == null ? other$player != null : !this$player.equals(other$player)) return false;
        final java.lang.Object this$target = this.getTarget();
        final java.lang.Object other$target = other.getTarget();
        if (this$target == null ? other$target != null : !this$target.equals(other$target)) return false;
        return true;
    }

    @java.lang.SuppressWarnings("all")
    @lombok.Generated
    protected boolean canEqual(final java.lang.Object other) {
        return other instanceof PostLoginEvent;
    }

    @java.lang.Override
    @java.lang.SuppressWarnings("all")
    @lombok.Generated
    public int hashCode() {
        final int PRIME = 59;
        int result = 1;
        final java.lang.Object $player = this.getPlayer();
        result = result * PRIME + ($player == null ? 43 : $player.hashCode());
        final java.lang.Object $target = this.getTarget();
        result = result * PRIME + ($target == null ? 43 : $target.hashCode());
        return result;
    }
}
