summaryrefslogtreecommitdiffstats
path: root/Essentials/src/com/earth2me/essentials/IUser.java
blob: a991c2d1a5cb01761bc0dcea8109a5125f9e621a (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
package com.earth2me.essentials;

import com.earth2me.essentials.commands.IEssentialsCommand;
import java.math.BigDecimal;
import java.util.Map;
import java.util.Set;
import net.ess3.api.ITeleport;
import org.bukkit.Location;
import org.bukkit.entity.Player;


public interface IUser
{
	long getLastTeleportTimestamp();

	boolean isAuthorized(String node);

	boolean isAuthorized(IEssentialsCommand cmd);

	boolean isAuthorized(IEssentialsCommand cmd, String permissionPrefix);

	void setLastTeleportTimestamp(long time);

	Location getLastLocation();

	Player getBase();

	BigDecimal getMoney();

	void takeMoney(BigDecimal value);

	void giveMoney(BigDecimal value);

	boolean canAfford(BigDecimal value);

	String getGroup();

	void setLastLocation();

	Location getHome(String name) throws Exception;

	Location getHome(Location loc) throws Exception;

	/**
	 * 'Hidden' Represents when a player is hidden from others. This status includes when the player is hidden via other
	 * supported plugins. Use isVanished() if you want to check if a user is vanished by Essentials.
	 *
	 * @return If the user is hidden or not
	 * @see isVanished
	 */
	boolean isHidden();

	void setHidden(boolean vanish);

	/**
	 * 'Vanished' Represents when a player is hidden from others by Essentials. This status does NOT include when the
	 * player is hidden via other plugins. Use isHidden() if you want to check if a user is vanished by any supported
	 * plugin.
	 *
	 * @return If the user is vanished or not
	 * @see isHidden
	 */
	boolean isVanished();

	void setVanished(boolean vanish);

	ITeleport getTeleport();

	void setJail(String jail);

	boolean isIgnoreExempt();

	boolean isAfk();

	void setAfk(final boolean set);

	void setLogoutLocation();

	Location getLogoutLocation();

	void setConfigProperty(String node, Object object);

	Set<String> getConfigKeys();

	Map<String, Object> getConfigMap();

	Map<String, Object> getConfigMap(String node);

	public void sendMessage(String message);

	public String getName();
}