From a6e979ec6c51387d3d7c9b0f7db0a5bda736f4e0 Mon Sep 17 00:00:00 2001 From: sk89q Date: Thu, 27 Mar 2014 21:07:38 -0700 Subject: [PATCH] Moved visitors to com.sk89q.worldedit.visitor. --- src/main/java/com/sk89q/worldedit/EditSession.java | 6 +++++- .../java/com/sk89q/worldedit/commands/RegionCommands.java | 2 +- .../{operation => visitor}/BreadthFirstSearch.java | 4 +++- .../worldedit/{operation => visitor}/DownwardVisitor.java | 3 ++- .../worldedit/{operation => visitor}/FlatRegionVisitor.java | 4 +++- .../worldedit/{operation => visitor}/RecursiveVisitor.java | 3 ++- .../worldedit/{operation => visitor}/RegionVisitor.java | 4 +++- 7 files changed, 19 insertions(+), 7 deletions(-) rename src/main/java/com/sk89q/worldedit/{operation => visitor}/BreadthFirstSearch.java (97%) rename src/main/java/com/sk89q/worldedit/{operation => visitor}/DownwardVisitor.java (95%) rename src/main/java/com/sk89q/worldedit/{operation => visitor}/FlatRegionVisitor.java (93%) rename src/main/java/com/sk89q/worldedit/{operation => visitor}/RecursiveVisitor.java (94%) rename src/main/java/com/sk89q/worldedit/{operation => visitor}/RegionVisitor.java (92%) diff --git a/src/main/java/com/sk89q/worldedit/EditSession.java b/src/main/java/com/sk89q/worldedit/EditSession.java index 0c57d8403..aa1c5b040 100644 --- a/src/main/java/com/sk89q/worldedit/EditSession.java +++ b/src/main/java/com/sk89q/worldedit/EditSession.java @@ -45,6 +45,10 @@ import com.sk89q.worldedit.shape.ArbitraryShape; import com.sk89q.worldedit.shape.RegionShape; import com.sk89q.worldedit.shape.WorldEditExpressionEnvironment; import com.sk89q.worldedit.util.TreeGenerator; +import com.sk89q.worldedit.visitor.DownwardVisitor; +import com.sk89q.worldedit.visitor.FlatRegionVisitor; +import com.sk89q.worldedit.visitor.RecursiveVisitor; +import com.sk89q.worldedit.visitor.RegionVisitor; import java.util.*; @@ -2255,7 +2259,7 @@ public class EditSession { * @return number of trees created * @throws MaxChangedBlocksException * @deprecated Use {@link com.sk89q.worldedit.generator.ForestGenerator} with a - * {@link com.sk89q.worldedit.operation.FlatRegionVisitor} + * {@link com.sk89q.worldedit.visitor.FlatRegionVisitor} */ @Deprecated public int makeForest(Iterable it, int upperY, int lowerY, diff --git a/src/main/java/com/sk89q/worldedit/commands/RegionCommands.java b/src/main/java/com/sk89q/worldedit/commands/RegionCommands.java index 1096b0176..b3d79cfb9 100644 --- a/src/main/java/com/sk89q/worldedit/commands/RegionCommands.java +++ b/src/main/java/com/sk89q/worldedit/commands/RegionCommands.java @@ -31,7 +31,7 @@ import com.sk89q.worldedit.filtering.GaussianKernel; import com.sk89q.worldedit.filtering.HeightMapFilter; import com.sk89q.worldedit.generator.FloraGenerator; import com.sk89q.worldedit.generator.ForestGenerator; -import com.sk89q.worldedit.operation.FlatRegionVisitor; +import com.sk89q.worldedit.visitor.FlatRegionVisitor; import com.sk89q.worldedit.operation.GroundScatterFunction; import com.sk89q.worldedit.masks.Mask; import com.sk89q.worldedit.operation.OperationHelper; diff --git a/src/main/java/com/sk89q/worldedit/operation/BreadthFirstSearch.java b/src/main/java/com/sk89q/worldedit/visitor/BreadthFirstSearch.java similarity index 97% rename from src/main/java/com/sk89q/worldedit/operation/BreadthFirstSearch.java rename to src/main/java/com/sk89q/worldedit/visitor/BreadthFirstSearch.java index 47d9feaa5..3b9979467 100644 --- a/src/main/java/com/sk89q/worldedit/operation/BreadthFirstSearch.java +++ b/src/main/java/com/sk89q/worldedit/visitor/BreadthFirstSearch.java @@ -17,11 +17,13 @@ * along with this program. If not, see . */ -package com.sk89q.worldedit.operation; +package com.sk89q.worldedit.visitor; import com.sk89q.worldedit.BlockVector; import com.sk89q.worldedit.Vector; import com.sk89q.worldedit.WorldEditException; +import com.sk89q.worldedit.operation.Operation; +import com.sk89q.worldedit.operation.RegionFunction; import java.util.*; diff --git a/src/main/java/com/sk89q/worldedit/operation/DownwardVisitor.java b/src/main/java/com/sk89q/worldedit/visitor/DownwardVisitor.java similarity index 95% rename from src/main/java/com/sk89q/worldedit/operation/DownwardVisitor.java rename to src/main/java/com/sk89q/worldedit/visitor/DownwardVisitor.java index 393ca35c7..78614ebe1 100644 --- a/src/main/java/com/sk89q/worldedit/operation/DownwardVisitor.java +++ b/src/main/java/com/sk89q/worldedit/visitor/DownwardVisitor.java @@ -17,11 +17,12 @@ * along with this program. If not, see . */ -package com.sk89q.worldedit.operation; +package com.sk89q.worldedit.visitor; import com.sk89q.worldedit.EditSession; import com.sk89q.worldedit.Vector; import com.sk89q.worldedit.masks.Mask; +import com.sk89q.worldedit.operation.RegionFunction; import java.util.List; diff --git a/src/main/java/com/sk89q/worldedit/operation/FlatRegionVisitor.java b/src/main/java/com/sk89q/worldedit/visitor/FlatRegionVisitor.java similarity index 93% rename from src/main/java/com/sk89q/worldedit/operation/FlatRegionVisitor.java rename to src/main/java/com/sk89q/worldedit/visitor/FlatRegionVisitor.java index 9fe3e86a2..816219205 100644 --- a/src/main/java/com/sk89q/worldedit/operation/FlatRegionVisitor.java +++ b/src/main/java/com/sk89q/worldedit/visitor/FlatRegionVisitor.java @@ -17,10 +17,12 @@ * along with this program. If not, see . */ -package com.sk89q.worldedit.operation; +package com.sk89q.worldedit.visitor; import com.sk89q.worldedit.Vector2D; import com.sk89q.worldedit.WorldEditException; +import com.sk89q.worldedit.operation.FlatRegionFunction; +import com.sk89q.worldedit.operation.Operation; import com.sk89q.worldedit.regions.CuboidRegion; import com.sk89q.worldedit.regions.FlatRegion; import com.sk89q.worldedit.regions.Region; diff --git a/src/main/java/com/sk89q/worldedit/operation/RecursiveVisitor.java b/src/main/java/com/sk89q/worldedit/visitor/RecursiveVisitor.java similarity index 94% rename from src/main/java/com/sk89q/worldedit/operation/RecursiveVisitor.java rename to src/main/java/com/sk89q/worldedit/visitor/RecursiveVisitor.java index 7bc6eb82c..aa9ef421a 100644 --- a/src/main/java/com/sk89q/worldedit/operation/RecursiveVisitor.java +++ b/src/main/java/com/sk89q/worldedit/visitor/RecursiveVisitor.java @@ -17,11 +17,12 @@ * along with this program. If not, see . */ -package com.sk89q.worldedit.operation; +package com.sk89q.worldedit.visitor; import com.sk89q.worldedit.EditSession; import com.sk89q.worldedit.Vector; import com.sk89q.worldedit.masks.Mask; +import com.sk89q.worldedit.operation.RegionFunction; /** * An implementation of an {@link BreadthFirstSearch} that uses a mask to diff --git a/src/main/java/com/sk89q/worldedit/operation/RegionVisitor.java b/src/main/java/com/sk89q/worldedit/visitor/RegionVisitor.java similarity index 92% rename from src/main/java/com/sk89q/worldedit/operation/RegionVisitor.java rename to src/main/java/com/sk89q/worldedit/visitor/RegionVisitor.java index 51772d57b..e87bea61b 100644 --- a/src/main/java/com/sk89q/worldedit/operation/RegionVisitor.java +++ b/src/main/java/com/sk89q/worldedit/visitor/RegionVisitor.java @@ -17,10 +17,12 @@ * along with this program. If not, see . */ -package com.sk89q.worldedit.operation; +package com.sk89q.worldedit.visitor; import com.sk89q.worldedit.Vector; import com.sk89q.worldedit.WorldEditException; +import com.sk89q.worldedit.operation.Operation; +import com.sk89q.worldedit.operation.RegionFunction; import com.sk89q.worldedit.regions.Region; /**