Class AgentArtifactHelperImpl
- java.lang.Object
-
- jetbrains.buildServer.agent.impl.artifacts.AgentArtifactHelperImpl
-
- All Implemented Interfaces:
AgentArtifactHelper
public class AgentArtifactHelperImpl extends Object implements AgentArtifactHelper
Created by Nikita.Skvortsov date: 02.08.2016.- Since:
- 2017.1
-
-
Constructor Summary
Constructors Constructor Description AgentArtifactHelperImpl(ArtifactsPublisher publisher, AllowedExternalArtifactPathRegistry allowedExternalArtifactPathRegistry, CurrentBuildTracker buildTracker)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description booleanisEnabled(ArtifactsPublisher publisher, String path)Whether or not the artifact should be published by the publishervoidpublishArtifactList(List<ArtifactDataInstance> artifacts, Map<String,String> commonProperties)Publish information about current build external artifacts.
-
-
-
Constructor Detail
-
AgentArtifactHelperImpl
public AgentArtifactHelperImpl(@NotNull ArtifactsPublisher publisher, @NotNull AllowedExternalArtifactPathRegistry allowedExternalArtifactPathRegistry, @NotNull CurrentBuildTracker buildTracker)
-
-
Method Detail
-
publishArtifactList
public void publishArtifactList(@NotNull List<ArtifactDataInstance> artifacts, @Nullable Map<String,String> commonProperties) throws IOExceptionDescription copied from interface:AgentArtifactHelperPublish information about current build external artifacts. Use this method to provide information about artifacts uploaded to external storage during the build.
Method will create and publish a file with json-serialized data. Note, that appending to already uploaded file is not supported. Subsequent calls will result in file being overwritten.- Specified by:
publishArtifactListin interfaceAgentArtifactHelper- Parameters:
artifacts- list with information about external artifactscommonProperties- common properties map for these list- Throws:
IOException- in case of errors
-
isEnabled
public boolean isEnabled(@NotNull ArtifactsPublisher publisher, @NotNull String path)Description copied from interface:AgentArtifactHelperWhether or not the artifact should be published by the publisher- Specified by:
isEnabledin interfaceAgentArtifactHelper- Parameters:
publisher- publisherpath- resulting artifact path- Returns:
- true if publisher should publish artifact
-
-