From 093778f2fb0249ea53669d2d4d8b01dd9789fedb Mon Sep 17 00:00:00 2001 From: Tobias Ottenweller Date: Sun, 26 May 2013 14:52:15 +0200 Subject: [PATCH] Added missing TeleportRequest class. --- .../craftinc/gates/util/TeleportRequest.java | 42 +++++++++++++++---- 1 file changed, 34 insertions(+), 8 deletions(-) diff --git a/src/de/craftinc/gates/util/TeleportRequest.java b/src/de/craftinc/gates/util/TeleportRequest.java index e01a162..abc3bc2 100644 --- a/src/de/craftinc/gates/util/TeleportRequest.java +++ b/src/de/craftinc/gates/util/TeleportRequest.java @@ -1,11 +1,37 @@ package de.craftinc.gates.util; -/** - * Created with IntelliJ IDEA. - * User: tobi - * Date: 26.05.13 - * Time: 14:28 - * To change this template use File | Settings | File Templates. - */ -public class TeleportRequest { +import org.bukkit.Location; +import org.bukkit.entity.Player; + +public class TeleportRequest +{ + private Player player; + private Location destination; + + + public TeleportRequest(Player player, Location destination) + { + if (player == null) { + throw new IllegalArgumentException("Player must not be null!"); + } + + if (destination == null) { + throw new IllegalArgumentException("Destination must not be null"); + } + + this.player = player; + this.destination = destination; + } + + + public Player getPlayer() + { + return player; + } + + + public Location getDestination() + { + return destination; + } }