From 5f1ed4448c0617efde6616dd970bcae8fbf4f3fb Mon Sep 17 00:00:00 2001 From: Xavier Hanin Date: Thu, 29 Dec 2005 15:47:31 +0000 Subject: [PATCH] FIX issue with cache path and cache fileset git-svn-id: https://svn.apache.org/repos/asf/incubator/ivy/trunk@484082 13f79535-47bb-0310-9956-ffa450edef68 --- src/java/fr/jayasoft/ivy/ant/IvyCacheFileset.java | 1 + src/java/fr/jayasoft/ivy/ant/IvyCachePath.java | 1 + src/java/fr/jayasoft/ivy/ant/IvyCacheTask.java | 6 +++++- 3 files changed, 7 insertions(+), 1 deletion(-) diff --git a/src/java/fr/jayasoft/ivy/ant/IvyCacheFileset.java b/src/java/fr/jayasoft/ivy/ant/IvyCacheFileset.java index e84189d5..58c85d0b 100644 --- a/src/java/fr/jayasoft/ivy/ant/IvyCacheFileset.java +++ b/src/java/fr/jayasoft/ivy/ant/IvyCacheFileset.java @@ -23,6 +23,7 @@ public class IvyCacheFileset extends IvyCacheTask { } public void execute() throws BuildException { + prepareAndCheck(); if (_setid == null) { throw new BuildException("setid is required in ivy cachefileset"); } diff --git a/src/java/fr/jayasoft/ivy/ant/IvyCachePath.java b/src/java/fr/jayasoft/ivy/ant/IvyCachePath.java index c0390d03..7adef222 100644 --- a/src/java/fr/jayasoft/ivy/ant/IvyCachePath.java +++ b/src/java/fr/jayasoft/ivy/ant/IvyCachePath.java @@ -29,6 +29,7 @@ public class IvyCachePath extends IvyCacheTask { } public void execute() throws BuildException { + prepareAndCheck(); if (_pathid == null) { throw new BuildException("pathid is required in ivy classpath"); } diff --git a/src/java/fr/jayasoft/ivy/ant/IvyCacheTask.java b/src/java/fr/jayasoft/ivy/ant/IvyCacheTask.java index f2c75334..6c282496 100644 --- a/src/java/fr/jayasoft/ivy/ant/IvyCacheTask.java +++ b/src/java/fr/jayasoft/ivy/ant/IvyCacheTask.java @@ -75,7 +75,7 @@ public abstract class IvyCacheTask extends IvyTask { _type = type; } - protected List getPaths() throws BuildException, ParseException, IOException { + protected void prepareAndCheck() { Ivy ivy = getIvyInstance(); ensureResolved(isHaltonfailure()); @@ -96,6 +96,10 @@ public abstract class IvyCacheTask extends IvyTask { throw new BuildException("no module name provided for ivy cachefileset: It can either be set explicitely via the attribute 'module' or via 'ivy.module' property or a prior call to "); } _artifactFilter = FilterHelper.getArtifactTypeFilter(_type); + } + + protected List getPaths() throws BuildException, ParseException, IOException { + Ivy ivy = getIvyInstance(); XmlReportParser parser = new XmlReportParser();