|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.apache.tools.ant.ProjectComponent org.apache.tools.ant.Task gate.util.ant.ExpandIvy
public class ExpandIvy
An ANT task that takes a CREOLE plugin and adds local copies of Ivy managed dependencies. This involves copying JAR files into the plugin directory as well as updating the creole.xml to substitute the IVY elements with appropriate JAR elements.
Field Summary |
---|
Fields inherited from class org.apache.tools.ant.Task |
---|
target, taskName, taskType, wrapper |
Fields inherited from class org.apache.tools.ant.ProjectComponent |
---|
description, location, project |
Constructor Summary | |
---|---|
ExpandIvy()
|
Method Summary | |
---|---|
void |
execute()
|
File |
getDir()
Get the CREOLE plugin directory being processed. |
boolean |
getFully()
Should we fully remove the link to Ivy by removing the dependency XML files. |
static org.apache.ivy.Ivy |
getIvy()
|
static org.apache.ivy.Ivy |
getIvy(File dir)
|
static org.apache.ivy.Ivy |
getIvy(URL settings)
|
static org.apache.ivy.Ivy |
getIvy(URL settings,
File dir)
|
static List<org.jdom.Element> |
getIvyElements(org.jdom.Document doc)
Processes the specified XML document file to extract all the <IVY> elements |
static List<org.jdom.Element> |
getIvyElements(URL creoleXML)
Processes the specified creole.xml file to extract all the <IVY> elements |
static File |
getIvyFile(org.jdom.Element element,
File creoleXML)
Turns an <IVY> XML element into a File instance by resolving relative to the creole.xml file. |
static String |
getIvyPath(org.jdom.Element element)
Retrieve the path to the Ivy file as specified in the XML element. |
File |
getSettings()
Get the Ivy settings file used to control dependency resolution. |
static URL |
getSettingsURL()
Attempts to find a custom Ivy settings file to use instead of the default configuration. |
boolean |
getVerbose()
If true then Ivy will spit out lots of messages while resolving dependencies. |
void |
setDir(File dir)
Set the CREOLE plugin directory to be processed. |
void |
setFully(boolean fully)
If true Ivy files referenced in creole.xml will be removed after they have been processed. |
void |
setSettings(File settings)
Specifies the settings file used to control dependency resolution. |
void |
setVerbose(boolean verbose)
Controls the log level of Ivy. |
Methods inherited from class org.apache.tools.ant.Task |
---|
bindToOwner, getOwningTarget, getRuntimeConfigurableWrapper, getTaskName, getTaskType, getWrapper, handleErrorFlush, handleErrorOutput, handleFlush, handleInput, handleOutput, init, isInvalid, log, log, log, log, maybeConfigure, perform, reconfigure, setOwningTarget, setRuntimeConfigurableWrapper, setTaskName, setTaskType |
Methods inherited from class org.apache.tools.ant.ProjectComponent |
---|
clone, getDescription, getLocation, getProject, setDescription, setLocation, setProject |
Methods inherited from class java.lang.Object |
---|
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public ExpandIvy()
Method Detail |
---|
public File getDir()
public void setDir(File dir)
dir
- the CREOLE plugin directory to be processed.public File getSettings()
public void setSettings(File settings)
settings
- the settings file used to control dependency resolution, or null
to use the default settings.public boolean getVerbose()
public void setVerbose(boolean verbose)
verbose
- if true then Ivy will spit out lots of messages while resolving
dependencies.public boolean getFully()
public void setFully(boolean fully)
fully
- if true Ivy files referenced in creole.xml will be removed after
they have been processed.public void execute() throws org.apache.tools.ant.BuildException
execute
in class org.apache.tools.ant.Task
org.apache.tools.ant.BuildException
public static List<org.jdom.Element> getIvyElements(URL creoleXML) throws org.jdom.JDOMException, IOException
creoleXML
- the URL of the creole.xml file to process
org.jdom.JDOMException
IOException
public static List<org.jdom.Element> getIvyElements(org.jdom.Document doc) throws org.jdom.JDOMException
doc
- the XML document to process
org.jdom.JDOMException
public static File getIvyFile(org.jdom.Element element, File creoleXML)
element
- the <IVY> element to convertcreoleXML
- the creole.xml file to resolve relative to
public static String getIvyPath(org.jdom.Element element)
element
- the <IVY> XML element to process
public static org.apache.ivy.Ivy getIvy() throws ParseException, IOException
ParseException
IOException
public static org.apache.ivy.Ivy getIvy(File dir) throws ParseException, IOException
ParseException
IOException
public static org.apache.ivy.Ivy getIvy(URL settings) throws ParseException, IOException
ParseException
IOException
public static org.apache.ivy.Ivy getIvy(URL settings, File dir) throws ParseException, IOException
ParseException
IOException
public static URL getSettingsURL()
ivy.settings.file
and then ivy.settings.url
. If
neither exist or can be converted to a valid URL then the method returns
null.
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |