org.exist.ant
Class XMLDBXQueryTask

java.lang.Object
  extended by org.apache.tools.ant.ProjectComponent
      extended by org.apache.tools.ant.Task
          extended by org.exist.ant.AbstractXMLDBTask
              extended by org.exist.ant.XMLDBXQueryTask
All Implemented Interfaces:
Cloneable

public class XMLDBXQueryTask
extends AbstractXMLDBTask

Ant task to execute an XQuery.

The query is either passed as nested text in the element, or via an attribute "query" or via a URL or via a query file. External variables declared in the XQuery can be set via one or more nested <variable> elements.

Author:
peter.klotz@blue-elephant-systems.com

Nested Class Summary
static class XMLDBXQueryTask.Variable
          Defines a nested element to set an XQuery variable
 
Constructor Summary
XMLDBXQueryTask()
           
 
Method Summary
 void addText(String text)
           
 void addVariable(XMLDBXQueryTask.Variable variable)
           
 void execute()
           
 void setDestDir(File destDir)
           
 void setOutputproperty(String outputproperty)
           
 void setQuery(String query)
           
 void setQueryFile(File queryFile)
           
 void setQueryUri(String queryUri)
           
 
Methods inherited from class org.exist.ant.AbstractXMLDBTask
setConfiguration, setDriver, setFailonerror, setInitdb, setPassword, setUri, setUser
 
Methods inherited from class org.apache.tools.ant.Task
bindToOwner, getOwningTarget, getRuntimeConfigurableWrapper, getTaskName, getTaskType, init, 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, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

XMLDBXQueryTask

public XMLDBXQueryTask()
Method Detail

execute

public void execute()
             throws org.apache.tools.ant.BuildException
Overrides:
execute in class org.apache.tools.ant.Task
Throws:
org.apache.tools.ant.BuildException

addText

public void addText(String text)

setQuery

public void setQuery(String query)

setQueryFile

public void setQueryFile(File queryFile)

setQueryUri

public void setQueryUri(String queryUri)

setDestDir

public void setDestDir(File destDir)

addVariable

public void addVariable(XMLDBXQueryTask.Variable variable)

setOutputproperty

public void setOutputproperty(String outputproperty)


Copyright (C) Wolfgang Meier. All rights reserved.