com.atlassian.bamboo.build.artifact
Class AbstractArtifactHandler

java.lang.Object
  extended by com.atlassian.bamboo.build.artifact.AbstractArtifactHandler
All Implemented Interfaces:
ArtifactHandler, InitablePluginModule<ArtifactHandlerModuleDescriptor>, BambooPluginModule
Direct Known Subclasses:
AbstractLocalArtifactHandler, BambooRemoteArtifactHandler, S3ArtifactHandler

public abstract class AbstractArtifactHandler
extends java.lang.Object
implements ArtifactHandler, InitablePluginModule<ArtifactHandlerModuleDescriptor>


Field Summary
protected static java.util.Set<AgentType> ALL_AGENT_TYPES
           
protected static java.util.Set<AgentType> LOCAL_AGENTS
           
static java.util.Set<AgentType> NON_LOCAL_AGENTS
           
 
Fields inherited from interface com.atlassian.bamboo.build.artifact.ArtifactHandler
LAN_SPEED, LOCAL_SPEED, WAN_SPEED
 
Constructor Summary
AbstractArtifactHandler(java.util.Set<AgentType> supportedAgents)
           
 
Method Summary
 boolean canHandleArtifact(ArtifactDefinitionContext artifact, java.util.Map<java.lang.String,java.lang.String> artifactHandlersConfiguration)
           
static ArtifactHandlerConfigProvider configProvider(java.util.Map<java.lang.String,java.lang.String> artifactHandlerConfiguration)
           
protected  java.lang.String getConfigurationKey(java.lang.String key)
           
protected  java.lang.String getConfigValue(java.util.Map<java.lang.String,java.lang.String> artifactHandlersConfiguration, java.lang.String key)
           
 java.util.Map<java.lang.String,java.lang.String> getDefaultConfiguration()
           
 ArtifactHandlerModuleDescriptor getModuleDescriptor()
           
 java.util.Set<AgentType> getSupportedAgents()
           
 void init(ArtifactHandlerModuleDescriptor moduleDescriptor)
          Initialises the Plugin with the plugin module descriptor
 void populateContextForEdit(java.util.Map<java.lang.String,java.lang.Object> context)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface com.atlassian.bamboo.build.artifact.ArtifactHandler
getArtifactLinkDataProvider, getArtifactLinkDataProvider, getSpeed, moveArtifactToGlobalStorage, publish, removeArtifactFromStorage, removeArtifactFromStorage, removeArtifactsFromStorage, removeArtifactsFromStorage, retrieve, retrieve
 

Field Detail

ALL_AGENT_TYPES

protected static final java.util.Set<AgentType> ALL_AGENT_TYPES

LOCAL_AGENTS

protected static final java.util.Set<AgentType> LOCAL_AGENTS

NON_LOCAL_AGENTS

public static final java.util.Set<AgentType> NON_LOCAL_AGENTS
Constructor Detail

AbstractArtifactHandler

public AbstractArtifactHandler(java.util.Set<AgentType> supportedAgents)
Method Detail

init

public void init(@NotNull
                 ArtifactHandlerModuleDescriptor moduleDescriptor)
Description copied from interface: InitablePluginModule
Initialises the Plugin with the plugin module descriptor

Specified by:
init in interface InitablePluginModule<ArtifactHandlerModuleDescriptor>
Parameters:
moduleDescriptor - Plugin module descriptor

canHandleArtifact

public boolean canHandleArtifact(ArtifactDefinitionContext artifact,
                                 java.util.Map<java.lang.String,java.lang.String> artifactHandlersConfiguration)
Specified by:
canHandleArtifact in interface ArtifactHandler

getDefaultConfiguration

@NotNull
public java.util.Map<java.lang.String,java.lang.String> getDefaultConfiguration()
Specified by:
getDefaultConfiguration in interface ArtifactHandler

populateContextForEdit

public void populateContextForEdit(@NotNull
                                   java.util.Map<java.lang.String,java.lang.Object> context)
Specified by:
populateContextForEdit in interface ArtifactHandler

getConfigValue

@Nullable
protected java.lang.String getConfigValue(java.util.Map<java.lang.String,java.lang.String> artifactHandlersConfiguration,
                                                   java.lang.String key)

getConfigurationKey

protected java.lang.String getConfigurationKey(java.lang.String key)

getSupportedAgents

@NotNull
public java.util.Set<AgentType> getSupportedAgents()
Specified by:
getSupportedAgents in interface ArtifactHandler

getModuleDescriptor

@NotNull
public ArtifactHandlerModuleDescriptor getModuleDescriptor()
Specified by:
getModuleDescriptor in interface ArtifactHandler

configProvider

@NotNull
public static ArtifactHandlerConfigProvider configProvider(@NotNull
                                                                   java.util.Map<java.lang.String,java.lang.String> artifactHandlerConfiguration)


Copyright © 2013 Atlassian Software Systems Pty Ltd. All Rights Reserved.