com.zanox.hudson.plugins
Class FTPPublisher

java.lang.Object
  extended by hudson.tasks.BuildStepCompatibilityLayer
      extended by hudson.tasks.Publisher
          extended by hudson.tasks.Notifier
              extended by com.zanox.hudson.plugins.FTPPublisher
All Implemented Interfaces:
hudson.ExtensionPoint, hudson.model.Describable<hudson.tasks.Publisher>, hudson.tasks.BuildStep

public class FTPPublisher
extends hudson.tasks.Notifier

This class implements the ftp publisher process by using the FTPSite.

HeadURL: $HeadURL: http://z-bld-02:8080/zxdev/zxant_test_environment/trunk/formatting/codeTemplates.xml $
Date: $Date: 2008-04-22 11:53:34 +0200 (Di, 22 Apr 2008) $
Revision: $Revision: 2451 $

Author:
$Author: ZANOX-COM\fit $

Nested Class Summary
static class FTPPublisher.DescriptorImpl
           This class holds the metadata for the FTPPublisher.
 
Nested classes/interfaces inherited from class hudson.tasks.Publisher
hudson.tasks.Publisher.DescriptorExtensionListImpl
 
Nested classes/interfaces inherited from interface hudson.ExtensionPoint
hudson.ExtensionPoint.LegacyInstancesAreScopedToHudson
 
Nested classes/interfaces inherited from interface hudson.tasks.BuildStep
hudson.tasks.BuildStep.PublisherList
 
Field Summary
static FTPPublisher.DescriptorImpl DESCRIPTOR
          Hold an instance of the Descriptor implementation of this publisher.
protected static java.text.SimpleDateFormat ID_FORMATTER
          This is a SimpleDateFormat instance to get a directory name which include a time stamp.
 
Fields inherited from interface hudson.tasks.BuildStep
BUILDERS, PUBLISHERS
 
Constructor Summary
FTPPublisher()
           
FTPPublisher(java.lang.String siteName)
          The constructor which take a configured ftp site name to publishing the artifacts.
 
Method Summary
 java.util.List<Entry> getEntries()
          The getter for the entries field.
 hudson.tasks.BuildStepMonitor getRequiredMonitorService()
           
 FTPSite getSite()
          This method returns the configured FTPSite object which match the siteName of the FTPPublisher instance.
 java.lang.String getSiteName()
           
 boolean isFlatten()
           
 boolean isSkip()
           
 boolean isUseTimestamps()
           
 boolean perform(hudson.model.AbstractBuild<?,?> build, hudson.Launcher launcher, hudson.model.BuildListener listener)
          
 void setFlatten(boolean flatten)
           
 void setSiteName(java.lang.String siteName)
           
 void setSkip(boolean skip)
           
 void setUseTimestamps(boolean useTimestamps)
           
 
Methods inherited from class hudson.tasks.Notifier
getDescriptor
 
Methods inherited from class hudson.tasks.Publisher
all, getProjectAction, needsToRunAfterFinalized, prebuild
 
Methods inherited from class hudson.tasks.BuildStepCompatibilityLayer
getProjectAction, getProjectActions, perform, prebuild
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface hudson.tasks.BuildStep
getProjectAction, getProjectActions, prebuild
 

Field Detail

DESCRIPTOR

@Extension
public static final FTPPublisher.DescriptorImpl DESCRIPTOR
Hold an instance of the Descriptor implementation of this publisher.


ID_FORMATTER

protected static final java.text.SimpleDateFormat ID_FORMATTER
This is a SimpleDateFormat instance to get a directory name which include a time stamp.

Constructor Detail

FTPPublisher

public FTPPublisher()

FTPPublisher

public FTPPublisher(java.lang.String siteName)
The constructor which take a configured ftp site name to publishing the artifacts.

Parameters:
siteName - the name of the ftp site configuration to use
Method Detail

setUseTimestamps

public void setUseTimestamps(boolean useTimestamps)

isUseTimestamps

public boolean isUseTimestamps()

setFlatten

public void setFlatten(boolean flatten)

isFlatten

public boolean isFlatten()

setSkip

public void setSkip(boolean skip)

isSkip

public boolean isSkip()

getEntries

public java.util.List<Entry> getEntries()
The getter for the entries field. (this field is set by the UI part of this plugin see config.jelly file)

Returns:
the value of the entries field

getSiteName

public java.lang.String getSiteName()

setSiteName

public void setSiteName(java.lang.String siteName)

getSite

public FTPSite getSite()
This method returns the configured FTPSite object which match the siteName of the FTPPublisher instance. (see Manage Hudson and System Configuration point FTP)

Returns:
the matching FTPSite or null

getRequiredMonitorService

public hudson.tasks.BuildStepMonitor getRequiredMonitorService()

perform

public boolean perform(hudson.model.AbstractBuild<?,?> build,
                       hudson.Launcher launcher,
                       hudson.model.BuildListener listener)
                throws java.lang.InterruptedException,
                       java.io.IOException

Specified by:
perform in interface hudson.tasks.BuildStep
Overrides:
perform in class hudson.tasks.BuildStepCompatibilityLayer
Parameters:
build -
launcher -
listener -
Returns:
Throws:
java.lang.InterruptedException
java.io.IOException
See Also:
hudson.tasks.BuildStep#perform(hudson.model.Build, hudson.Launcher, hudson.model.BuildListener)


Copyright © 2011. All Rights Reserved.