Bukkit  1.4.7-R1.0
 All Classes Namespaces Files Functions Variables Enumerator Pages
PlayerTeleportEvent.java
Go to the documentation of this file.
1 package org.bukkit.event.player;
2 
3 import org.bukkit.Location;
4 import org.bukkit.entity.Player;
5 import org.bukkit.event.HandlerList;
6 
10 public class PlayerTeleportEvent extends PlayerMoveEvent {
11  private static final HandlerList handlers = new HandlerList();
12  private TeleportCause cause = TeleportCause.UNKNOWN;
13 
14  public PlayerTeleportEvent(final Player player, final Location from, final Location to) {
15  super(player, from, to);
16  }
17 
18  public PlayerTeleportEvent(final Player player, final Location from, final Location to, final TeleportCause cause) {
19  this(player, from, to);
20 
21  this.cause = cause;
22  }
23 
30  return cause;
31  }
32 
33  public enum TeleportCause {
58  }
59 
60  @Override
62  return handlers;
63  }
64 
65  public static HandlerList getHandlerList() {
66  return handlers;
67  }
68 }