From af11707da08b70c8ef90ff513b5e66c457c1c985 Mon Sep 17 00:00:00 2001 From: Ryan Ernst Date: Fri, 18 Dec 2015 14:36:36 -0800 Subject: [PATCH] Remove unused method impl in AntTask and make abstract --- .../main/groovy/org/elasticsearch/gradle/AntTask.groovy | 9 ++------- 1 file changed, 2 insertions(+), 7 deletions(-) diff --git a/buildSrc/src/main/groovy/org/elasticsearch/gradle/AntTask.groovy b/buildSrc/src/main/groovy/org/elasticsearch/gradle/AntTask.groovy index 80541b43f42..1df6306400b 100644 --- a/buildSrc/src/main/groovy/org/elasticsearch/gradle/AntTask.groovy +++ b/buildSrc/src/main/groovy/org/elasticsearch/gradle/AntTask.groovy @@ -35,7 +35,7 @@ import java.nio.charset.Charset * * Logging for the task is customizable for subclasses by overriding makeLogger. */ -public class AntTask extends DefaultTask { +public abstract class AntTask extends DefaultTask { /** * A buffer that will contain the output of the ant code run, @@ -76,12 +76,7 @@ public class AntTask extends DefaultTask { } /** Runs the doAnt closure. This can be overridden by subclasses instead of having to set a closure. */ - protected void runAnt(AntBuilder ant) { - if (doAnt == null) { - throw new GradleException("Missing doAnt for ${name}") - } - doAnt(ant) - } + protected abstract void runAnt(AntBuilder ant); /** Create the logger the ant runner will use, with the given stream for error/output. */ protected BuildLogger makeLogger(PrintStream stream, int outputLevel) {