Class GenericArtifact.Builder
- java.lang.Object
-
- com.oracle.bmc.artifacts.model.GenericArtifact.Builder
-
- Enclosing class:
- GenericArtifact
public static class GenericArtifact.Builder extends Object
-
-
Constructor Summary
Constructors Constructor Description Builder()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description GenericArtifact.Builder
artifactPath(String artifactPath)
A user-defined path to describe the location of an artifact.GenericArtifact
build()
GenericArtifact.Builder
compartmentId(String compartmentId)
The OCID of the repository’s compartment.GenericArtifact.Builder
copy(GenericArtifact model)
GenericArtifact.Builder
definedTags(Map<String,Map<String,Object>> definedTags)
Defined tags for this resource.GenericArtifact.Builder
displayName(String displayName)
The artifact name with the format of: . GenericArtifact.Builder
freeformTags(Map<String,String> freeformTags)
Free-form tags for this resource.GenericArtifact.Builder
id(String id)
The OCID of the artifact.GenericArtifact.Builder
lifecycleState(GenericArtifact.LifecycleState lifecycleState)
The current state of the artifact.GenericArtifact.Builder
repositoryId(String repositoryId)
The OCID of the repository.GenericArtifact.Builder
sha256(String sha256)
The SHA256 digest for the artifact.GenericArtifact.Builder
sizeInBytes(Long sizeInBytes)
The size of the artifact in bytes.GenericArtifact.Builder
timeCreated(Date timeCreated)
An RFC 3339 timestamp indicating when the repository was created.GenericArtifact.Builder
version(String version)
A user-defined string to describe the artifact version.
-
-
-
Method Detail
-
id
public GenericArtifact.Builder id(String id)
The OCID of the artifact.Example: ocid1.genericartifact.oc1..exampleuniqueID
- Parameters:
id
- the value to set- Returns:
- this builder
-
displayName
public GenericArtifact.Builder displayName(String displayName)
The artifact name with the format of: . The artifact name is truncated to a maximum length of 255.
Example: project01/my-web-app/artifact-abc:1.0.0
- Parameters:
displayName
- the value to set- Returns:
- this builder
-
compartmentId
public GenericArtifact.Builder compartmentId(String compartmentId)
The OCID of the repository’s compartment.- Parameters:
compartmentId
- the value to set- Returns:
- this builder
-
repositoryId
public GenericArtifact.Builder repositoryId(String repositoryId)
The OCID of the repository.- Parameters:
repositoryId
- the value to set- Returns:
- this builder
-
artifactPath
public GenericArtifact.Builder artifactPath(String artifactPath)
A user-defined path to describe the location of an artifact.Slashes do not create a directory structure, but you can use slashes to organize the repository. An artifact path does not include an artifact version.
Example: project01/my-web-app/artifact-abc
- Parameters:
artifactPath
- the value to set- Returns:
- this builder
-
version
public GenericArtifact.Builder version(String version)
A user-defined string to describe the artifact version.Example: 1.1.0 or 1.2-beta-2
- Parameters:
version
- the value to set- Returns:
- this builder
-
sha256
public GenericArtifact.Builder sha256(String sha256)
The SHA256 digest for the artifact.When you upload an artifact to the repository, a SHA256 digest is calculated and added to the artifact properties.
- Parameters:
sha256
- the value to set- Returns:
- this builder
-
sizeInBytes
public GenericArtifact.Builder sizeInBytes(Long sizeInBytes)
The size of the artifact in bytes.- Parameters:
sizeInBytes
- the value to set- Returns:
- this builder
-
lifecycleState
public GenericArtifact.Builder lifecycleState(GenericArtifact.LifecycleState lifecycleState)
The current state of the artifact.- Parameters:
lifecycleState
- the value to set- Returns:
- this builder
-
freeformTags
public GenericArtifact.Builder freeformTags(Map<String,String> freeformTags)
Free-form tags for this resource.Each tag is a simple key-value pair with no predefined name, type, or namespace. For more information, see Resource Tags.
Example: {"Department": "Finance"}
- Parameters:
freeformTags
- the value to set- Returns:
- this builder
-
definedTags
public GenericArtifact.Builder definedTags(Map<String,Map<String,Object>> definedTags)
Defined tags for this resource.Each key is predefined and scoped to a namespace. For more information, see Resource Tags.
Example: {"Operations": {"CostCenter": "42"}}
- Parameters:
definedTags
- the value to set- Returns:
- this builder
-
timeCreated
public GenericArtifact.Builder timeCreated(Date timeCreated)
An RFC 3339 timestamp indicating when the repository was created.- Parameters:
timeCreated
- the value to set- Returns:
- this builder
-
build
public GenericArtifact build()
-
copy
public GenericArtifact.Builder copy(GenericArtifact model)
-
-