public interface DownloadedArtifact extends Artifact
You can use this artifact object to update some properties of the artifact as well
as to add new assets to it. After that, the artifact can be uploaded to the Comet
using OnlineExperiment.logArtifact(Artifact) method.
| Modifier and Type | Method and Description |
|---|---|
Set<String> |
getAliases()
Returns set of aliases associated with the artifact.
|
String |
getArtifactId()
Returns unique identifier of the artifact.
|
String |
getArtifactType()
Returns type of the artifact.
|
String |
getFullName()
Returns the fully qualified name of the artifact in form 'workspace/name:version'.
|
Map<String,Object> |
getMetadata()
Returns metadata associated with artifact.
|
String |
getName()
Returns name of the artifact.
|
String |
getVersion()
Returns the version of this artifact represented in semantic version format.
|
Set<String> |
getVersionTags()
Returns set of TAGs associated with current version of the artifact.
|
String |
getWorkspace()
Returns workspace name where artifact was logged.
|
String |
incrementMajorVersion()
Allows bumping artifact version to the next major version.
|
String |
incrementMinorVersion()
Allows bumping artifact version to the next minor version.
|
String |
incrementPatchVersion()
Allows bumping artifact version to the next patch version.
|
void |
setAliases(Set<String> aliases)
Sets the new aliases to be associated with the artifact.
|
boolean |
setVersion(String version)
Sets new version for this artifact.
|
void |
setVersionTags(Set<String> tags)
Sets the TAGs for the new version of the artifact.
|
addAsset, addAsset, addAsset, addAsset, addAsset, addAsset, addAsset, addAssetFolder, addAssetFolder, addAssetFolder, addAssetFolder, addRemoteAsset, addRemoteAsset, addRemoteAsset, getAssets, newArtifactString getArtifactId()
String getName()
String getFullName()
String getArtifactType()
String getWorkspace()
String getVersion()
boolean setVersion(String version)
false will be returned. The Comet may accept version lower than current if it
was not logged before. Thus, in general, it is safer to always log the greater version or check value returned
but this method.
The version string should follow the semantic versioning rules and be in the form:
1.2.3-beta.4+sha899d8g79f87.
See ArtifactBuilder.withVersion(String) for details about version format.
version - the new version of the artifact.true if new version is valid, i.e., greater than current. The returned value can be used for
quick check of the new version. If true returned then new version will be accepted by Comet backend.
Otherwise, it may depend on backend already having provided artifact version logged.String incrementMajorVersion()
See ArtifactBuilder.withVersion(String) for details about version format.
String incrementMinorVersion()
See ArtifactBuilder.withVersion(String) for details about version format.
String incrementPatchVersion()
See ArtifactBuilder.withVersion(String) for details about version format.
Set<String> getVersionTags()
void setVersionTags(Set<String> tags)
tags - the set of version TAGs to replace existing.Set<String> getAliases()
void setAliases(Set<String> aliases)
aliases - the set of aliases to be associated with artifact.Copyright © 2022. All rights reserved.