From 7c4a67d32b85c2bf86d97a0ced5703760ea53c03 Mon Sep 17 00:00:00 2001 From: sk89q Date: Wed, 26 Mar 2014 15:46:46 -0700 Subject: [PATCH] FlatRegionApplicator -> FlatRegionVisitor. --- src/main/java/com/sk89q/worldedit/EditSession.java | 6 +++--- .../java/com/sk89q/worldedit/commands/RegionCommands.java | 6 +++--- .../{FlatRegionApplicator.java => FlatRegionVisitor.java} | 4 ++-- 3 files changed, 8 insertions(+), 8 deletions(-) rename src/main/java/com/sk89q/worldedit/operation/{FlatRegionApplicator.java => FlatRegionVisitor.java} (93%) diff --git a/src/main/java/com/sk89q/worldedit/EditSession.java b/src/main/java/com/sk89q/worldedit/EditSession.java index f07c45ac8..d4a186dd2 100644 --- a/src/main/java/com/sk89q/worldedit/EditSession.java +++ b/src/main/java/com/sk89q/worldedit/EditSession.java @@ -29,12 +29,12 @@ import com.sk89q.worldedit.expression.ExpressionException; import com.sk89q.worldedit.expression.runtime.RValue; import com.sk89q.worldedit.generator.ForestGenerator; import com.sk89q.worldedit.generator.GardenPatchGenerator; +import com.sk89q.worldedit.operation.FlatRegionVisitor; import com.sk89q.worldedit.operation.GroundScatterFunction; import com.sk89q.worldedit.interpolation.Interpolation; import com.sk89q.worldedit.interpolation.KochanekBartelsInterpolation; import com.sk89q.worldedit.interpolation.Node; import com.sk89q.worldedit.masks.Mask; -import com.sk89q.worldedit.operation.FlatRegionApplicator; import com.sk89q.worldedit.operation.OperationHelper; import com.sk89q.worldedit.patterns.Pattern; import com.sk89q.worldedit.regions.CuboidRegion; @@ -2591,7 +2591,7 @@ public class EditSession { scatter.setRange(region); // Generate those patches! - FlatRegionApplicator operation = new FlatRegionApplicator(region, scatter); + FlatRegionVisitor operation = new FlatRegionVisitor(region, scatter); OperationHelper.completeLegacy(operation); return operation.getAffected(); @@ -2654,7 +2654,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.FlatRegionApplicator} + * {@link com.sk89q.worldedit.operation.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 be7725879..1096b0176 100644 --- a/src/main/java/com/sk89q/worldedit/commands/RegionCommands.java +++ b/src/main/java/com/sk89q/worldedit/commands/RegionCommands.java @@ -31,9 +31,9 @@ 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.operation.GroundScatterFunction; import com.sk89q.worldedit.masks.Mask; -import com.sk89q.worldedit.operation.FlatRegionApplicator; import com.sk89q.worldedit.operation.OperationHelper; import com.sk89q.worldedit.patterns.Pattern; import com.sk89q.worldedit.patterns.SingleBlockPattern; @@ -552,7 +552,7 @@ public class RegionCommands { scatter.setRange(region); // Generate that forest - FlatRegionApplicator operation = new FlatRegionApplicator(region, scatter); + FlatRegionVisitor operation = new FlatRegionVisitor(region, scatter); OperationHelper.complete(operation); player.print(operation.getAffected() + " trees created."); @@ -581,7 +581,7 @@ public class RegionCommands { scatter.setRange(region); // Generate that flora - FlatRegionApplicator operation = new FlatRegionApplicator(region, scatter); + FlatRegionVisitor operation = new FlatRegionVisitor(region, scatter); OperationHelper.complete(operation); player.print(operation.getAffected() + " flora created."); diff --git a/src/main/java/com/sk89q/worldedit/operation/FlatRegionApplicator.java b/src/main/java/com/sk89q/worldedit/operation/FlatRegionVisitor.java similarity index 93% rename from src/main/java/com/sk89q/worldedit/operation/FlatRegionApplicator.java rename to src/main/java/com/sk89q/worldedit/operation/FlatRegionVisitor.java index 0f7d42933..9fe3e86a2 100644 --- a/src/main/java/com/sk89q/worldedit/operation/FlatRegionApplicator.java +++ b/src/main/java/com/sk89q/worldedit/operation/FlatRegionVisitor.java @@ -28,13 +28,13 @@ import com.sk89q.worldedit.regions.Region; /** * Utility class to apply region functions to {@link com.sk89q.worldedit.regions.Region}. */ -public class FlatRegionApplicator implements Operation { +public class FlatRegionVisitor implements Operation { private final FlatRegion flatRegion; private final FlatRegionFunction function; private int affected = 0; - public FlatRegionApplicator(Region region, FlatRegionFunction function) { + public FlatRegionVisitor(Region region, FlatRegionFunction function) { this.function = function; if (region instanceof FlatRegion) {