Interface BuildArtifact
-
- All Superinterfaces:
BuildArtifactInfo
public interface BuildArtifact extends BuildArtifactInfo
Represents build artifact file- Since:
- 6.5
- Author:
- Eugene Petrenko (eugene.petrenko@gmail.com)
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description java.util.Collection<BuildArtifact>
getChildren()
Returns sub items of the artifact.java.io.InputStream
getInputStream()
Creates input stream for this artifact.long
getSize()
Computes artifact size.long
getTimestamp()
boolean
isArchive()
boolean
isContainer()
boolean
isDirectory()
boolean
isFile()
-
Methods inherited from interface jetbrains.buildServer.serverSide.artifacts.BuildArtifactInfo
getName, getRelativePath
-
-
-
-
Method Detail
-
isDirectory
boolean isDirectory()
- Returns:
- true if this artifact represents a directory
- Since:
- 6.5
-
isArchive
boolean isArchive()
- Returns:
- true if this artifact is archive file (.zip, .jar, .tar.gz, etc.)
- Since:
- 8.0
-
isFile
boolean isFile()
- Returns:
- true if this artifact is regular file (may be archive at the same time)
- Since:
- 8.0
-
isContainer
boolean isContainer()
- Returns:
- true if this artifact is directory or (archive if used BuildArtifactsViewMode with isViewArchivesContent == true)
- Since:
- 8.0
-
getSize
long getSize()
Computes artifact size. This method is not recursive.- Returns:
- artifact size for file or 0 otherwise
- Since:
- 6.5
-
getTimestamp
long getTimestamp()
- Returns:
- artifact last modification timestamp
- Since:
- 6.5
-
getInputStream
@NotNull java.io.InputStream getInputStream() throws java.io.IOException
Creates input stream for this artifact. Client must close the stream at end Exception will be thrown if artifact does not contains content- Returns:
- file content or null
- Throws:
java.io.IOException
- Since:
- 6.5
-
getChildren
@NotNull java.util.Collection<BuildArtifact> getChildren()
Returns sub items of the artifact. Sub items is child artifacts if artifacts is directory. Or returns archive root's child if used BuildArtifactsViewMode with isViewArchivesContent==true- Returns:
- see above
- Since:
- 6.5
-
-