Passed
Pull Request — master (#5)
by Manuel
04:01
created

LabyPlayerJoinEvent(ProxiedPlayer,List,String,int,boolean)   A

Complexity

Conditions 1

Size

Total Lines 9

Duplication

Lines 0
Ratio 0 %

Importance

Changes 1
Bugs 0 Features 0
Metric Value
cc 1
c 1
b 0
f 0
dl 0
loc 9
rs 9.95
1
package net.labymod.server.bungeecord.event;
2
3
import edu.umd.cs.findbugs.annotations.NonNull;
4
import net.labymod.server.common.addon.model.AddonModel;
5
import net.md_5.bungee.api.connection.ProxiedPlayer;
6
import net.md_5.bungee.api.plugin.Event;
7
8
import java.util.List;
9
10
/**
11
 * The {@link LabyPlayerJoinEvent} extends {@link Event} there are triggered when the {@link ProxiedPlayer} join
12
 * the proxy server.
13
 *
14
 * @author Manuel Kollus
15
 * @version 2.0
16
 * @since 2.0
17
 */
18
public class LabyPlayerJoinEvent extends Event {
19
20
    private ProxiedPlayer proxiedPlayer;
21
    private List<AddonModel> addons;
22
    private String modificationVersion;
23
    private int chunkCachingVersion;
24
    private boolean chunkCachingEnabled;
25
26
    public LabyPlayerJoinEvent( @NonNull ProxiedPlayer proxiedPlayer, @NonNull List<AddonModel> addons,
27
                                @NonNull String modificationVersion,
28
                                int chunkCachingVersion,
29
                                boolean chunkCachingEnabled ) {
30
        this.proxiedPlayer = proxiedPlayer;
31
        this.addons = addons;
32
        this.modificationVersion = modificationVersion;
33
        this.chunkCachingVersion = chunkCachingVersion;
34
        this.chunkCachingEnabled = chunkCachingEnabled;
35
    }
36
37
    @NonNull
38
    public ProxiedPlayer proxiedPlayer( ) {
39
        return this.proxiedPlayer;
40
    }
41
42
    @NonNull
43
    public List<AddonModel> addons( ) {
44
        return this.addons;
45
    }
46
47
    @NonNull
48
    public String modificationVersion( ) {
49
        return this.modificationVersion;
50
    }
51
52
    public int chunkCachingVersion( ) {
53
        return this.chunkCachingVersion;
54
    }
55
56
    public boolean chunkCachingEnabled( ) {
57
        return this.chunkCachingEnabled;
58
    }
59
}
60