From c535ad8682d32f1d1d76b1ab57cbdadecf3e852b Mon Sep 17 00:00:00 2001 From: sk89q Date: Mon, 14 Jul 2014 02:15:21 -0700 Subject: [PATCH] Have BukkitEntity.getState() return null for now. --- src/bukkit/java/com/sk89q/worldedit/bukkit/BukkitEntity.java | 2 +- src/main/java/com/sk89q/worldedit/entity/Entity.java | 5 ++++- 2 files changed, 5 insertions(+), 2 deletions(-) diff --git a/src/bukkit/java/com/sk89q/worldedit/bukkit/BukkitEntity.java b/src/bukkit/java/com/sk89q/worldedit/bukkit/BukkitEntity.java index 1625c572a..262a450f1 100644 --- a/src/bukkit/java/com/sk89q/worldedit/bukkit/BukkitEntity.java +++ b/src/bukkit/java/com/sk89q/worldedit/bukkit/BukkitEntity.java @@ -74,7 +74,7 @@ class BukkitEntity implements Entity { @Override public BaseEntity getState() { - throw new UnsupportedOperationException("Not implemented yet"); + return null; } @Override diff --git a/src/main/java/com/sk89q/worldedit/entity/Entity.java b/src/main/java/com/sk89q/worldedit/entity/Entity.java index 800f61c72..7c6d68e7c 100644 --- a/src/main/java/com/sk89q/worldedit/entity/Entity.java +++ b/src/main/java/com/sk89q/worldedit/entity/Entity.java @@ -22,6 +22,8 @@ package com.sk89q.worldedit.entity; import com.sk89q.worldedit.extent.Extent; import com.sk89q.worldedit.util.Location; +import javax.annotation.Nullable; + /** * A reference to an instance of an entity that exists in an {@link Extent} * and thus would have position and similar details. @@ -37,8 +39,9 @@ public interface Entity { /** * Get a copy of the entity's state. * - * @return the entity's state + * @return the entity's state or null if one cannot be gotten */ + @Nullable BaseEntity getState(); /**