org.apache.lenya.cms.ant
Class PublicationTask

java.lang.Object
  extended by org.apache.tools.ant.ProjectComponent
      extended by org.apache.tools.ant.Task
          extended by org.apache.lenya.cms.ant.PublicationTask
Direct Known Subclasses:
ChangeHrefTask, ChangeVisibilityTask, ComputeNewDocumentId, DeactivateResourcesTask, DeleteNodeTask, DeleteSchedulerEntryTask, DocumentCreatorTask, DocumentIdToFile, DocumentIdToPath, DocumentOperationTask, InitWorkflowHistoryTask, InsertLabelTask, LinkRewriteTask, MoveDocumentTask, MoveSiteTreeNodeTask, RemoveLabelTask, RenameLabelTask, ResourcePublisher, SetIdentifier, SiteTreeResetTask, StaticHTMLExporter, TreePublisher, TwoNodesTask, WriteDCParametersTask

public abstract class PublicationTask
extends org.apache.tools.ant.Task

Abstract base class for publication-dependent Ant tasks. It requires some project parameters that are set by the AntTask.


Field Summary
 
Fields inherited from class org.apache.tools.ant.Task
description, location, target, taskName, taskType, wrapper
 
Fields inherited from class org.apache.tools.ant.ProjectComponent
project
 
Constructor Summary
PublicationTask()
          Creates a new instance of PublicationTask
 
Method Summary
protected  void assertString(java.lang.String string)
          Utility method for assertion that a string is !
protected  java.lang.String getContextPrefix()
          Return the context prefix.
protected  Publication getPublication()
          Get the publication
protected  java.io.File getPublicationDirectory()
          Returns the publication directory.
protected  java.lang.String getPublicationId()
          Returns the publication ID.
protected  java.io.File getServletContext()
          Returns the servlet context (e.g., tomcat/webapp/lenya)
 
Methods inherited from class org.apache.tools.ant.Task
execute, getDescription, getLocation, getOwningTarget, getRuntimeConfigurableWrapper, getTaskName, getTaskType, getWrapper, handleErrorFlush, handleErrorOutput, handleFlush, handleInput, handleOutput, init, isInvalid, log, log, maybeConfigure, perform, reconfigure, setDescription, setLocation, setOwningTarget, setRuntimeConfigurableWrapper, setTaskName, setTaskType
 
Methods inherited from class org.apache.tools.ant.ProjectComponent
getProject, setProject
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

PublicationTask

public PublicationTask()
Creates a new instance of PublicationTask

Method Detail

getPublicationDirectory

protected java.io.File getPublicationDirectory()
Returns the publication directory.

Returns:
a the path to the publication directory as a File

getContextPrefix

protected java.lang.String getContextPrefix()
Return the context prefix.

Returns:
the context-prefix

getPublicationId

protected java.lang.String getPublicationId()
Returns the publication ID.

Returns:
the publication-id

getServletContext

protected java.io.File getServletContext()
Returns the servlet context (e.g., tomcat/webapp/lenya)

Returns:
the servlet-context

getPublication

protected Publication getPublication()
                              throws org.apache.tools.ant.BuildException
Get the publication

Returns:
the publication
Throws:
org.apache.tools.ant.BuildException - if the publication could not be found

assertString

protected void assertString(java.lang.String string)
Utility method for assertion that a string is != null and != ""

Parameters:
string - the string to check


Copyright © 1999-2005 Apache Software Foundation. All Rights Reserved.