Class Repository (1.51.0)

public final class Repository extends GeneratedMessageV3 implements RepositoryOrBuilder

A Repository for storing artifacts with a specific format.

Protobuf type google.devtools.artifactregistry.v1.Repository

Implements

RepositoryOrBuilder

Static Fields

CLEANUP_POLICIES_FIELD_NUMBER

public static final int CLEANUP_POLICIES_FIELD_NUMBER
Field Value
Type Description
int

CLEANUP_POLICY_DRY_RUN_FIELD_NUMBER

public static final int CLEANUP_POLICY_DRY_RUN_FIELD_NUMBER
Field Value
Type Description
int

CREATE_TIME_FIELD_NUMBER

public static final int CREATE_TIME_FIELD_NUMBER
Field Value
Type Description
int

DESCRIPTION_FIELD_NUMBER

public static final int DESCRIPTION_FIELD_NUMBER
Field Value
Type Description
int

DOCKER_CONFIG_FIELD_NUMBER

public static final int DOCKER_CONFIG_FIELD_NUMBER
Field Value
Type Description
int

FORMAT_FIELD_NUMBER

public static final int FORMAT_FIELD_NUMBER
Field Value
Type Description
int

KMS_KEY_NAME_FIELD_NUMBER

public static final int KMS_KEY_NAME_FIELD_NUMBER
Field Value
Type Description
int

LABELS_FIELD_NUMBER

public static final int LABELS_FIELD_NUMBER
Field Value
Type Description
int

MAVEN_CONFIG_FIELD_NUMBER

public static final int MAVEN_CONFIG_FIELD_NUMBER
Field Value
Type Description
int

MODE_FIELD_NUMBER

public static final int MODE_FIELD_NUMBER
Field Value
Type Description
int

NAME_FIELD_NUMBER

public static final int NAME_FIELD_NUMBER
Field Value
Type Description
int

REMOTE_REPOSITORY_CONFIG_FIELD_NUMBER

public static final int REMOTE_REPOSITORY_CONFIG_FIELD_NUMBER
Field Value
Type Description
int

SATISFIES_PZS_FIELD_NUMBER

public static final int SATISFIES_PZS_FIELD_NUMBER
Field Value
Type Description
int

SIZE_BYTES_FIELD_NUMBER

public static final int SIZE_BYTES_FIELD_NUMBER
Field Value
Type Description
int

UPDATE_TIME_FIELD_NUMBER

public static final int UPDATE_TIME_FIELD_NUMBER
Field Value
Type Description
int

VIRTUAL_REPOSITORY_CONFIG_FIELD_NUMBER

public static final int VIRTUAL_REPOSITORY_CONFIG_FIELD_NUMBER
Field Value
Type Description
int

Static Methods

getDefaultInstance()

public static Repository getDefaultInstance()
Returns
Type Description
Repository

getDescriptor()

public static final Descriptors.Descriptor getDescriptor()
Returns
Type Description
Descriptor

newBuilder()

public static Repository.Builder newBuilder()
Returns
Type Description
Repository.Builder

newBuilder(Repository prototype)

public static Repository.Builder newBuilder(Repository prototype)
Parameter
Name Description
prototype Repository
Returns
Type Description
Repository.Builder

parseDelimitedFrom(InputStream input)

public static Repository parseDelimitedFrom(InputStream input)
Parameter
Name Description
input InputStream
Returns
Type Description
Repository
Exceptions
Type Description
IOException

parseDelimitedFrom(InputStream input, ExtensionRegistryLite extensionRegistry)

public static Repository parseDelimitedFrom(InputStream input, ExtensionRegistryLite extensionRegistry)
Parameters
Name Description
input InputStream
extensionRegistry ExtensionRegistryLite
Returns
Type Description
Repository
Exceptions
Type Description
IOException

parseFrom(byte[] data)

public static Repository parseFrom(byte[] data)
Parameter
Name Description
data byte[]
Returns
Type Description
Repository
Exceptions
Type Description
InvalidProtocolBufferException

parseFrom(byte[] data, ExtensionRegistryLite extensionRegistry)

public static Repository parseFrom(byte[] data, ExtensionRegistryLite extensionRegistry)
Parameters
Name Description
data byte[]
extensionRegistry ExtensionRegistryLite
Returns
Type Description
Repository
Exceptions
Type Description
InvalidProtocolBufferException

parseFrom(ByteString data)

public static Repository parseFrom(ByteString data)
Parameter
Name Description
data ByteString
Returns
Type Description
Repository
Exceptions
Type Description
InvalidProtocolBufferException

parseFrom(ByteString data, ExtensionRegistryLite extensionRegistry)

public static Repository parseFrom(ByteString data, ExtensionRegistryLite extensionRegistry)
Parameters
Name Description
data ByteString
extensionRegistry ExtensionRegistryLite
Returns
Type Description
Repository
Exceptions
Type Description
InvalidProtocolBufferException

parseFrom(CodedInputStream input)

public static Repository parseFrom(CodedInputStream input)
Parameter
Name Description
input CodedInputStream
Returns
Type Description
Repository
Exceptions
Type Description
IOException

parseFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)

public static Repository parseFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)
Parameters
Name Description
input CodedInputStream
extensionRegistry ExtensionRegistryLite
Returns
Type Description
Repository
Exceptions
Type Description
IOException

parseFrom(InputStream input)

public static Repository parseFrom(InputStream input)
Parameter
Name Description
input InputStream
Returns
Type Description
Repository
Exceptions
Type Description
IOException

parseFrom(InputStream input, ExtensionRegistryLite extensionRegistry)

public static Repository parseFrom(InputStream input, ExtensionRegistryLite extensionRegistry)
Parameters
Name Description
input InputStream
extensionRegistry ExtensionRegistryLite
Returns
Type Description
Repository
Exceptions
Type Description
IOException

parseFrom(ByteBuffer data)

public static Repository parseFrom(ByteBuffer data)
Parameter
Name Description
data ByteBuffer
Returns
Type Description
Repository
Exceptions
Type Description
InvalidProtocolBufferException

parseFrom(ByteBuffer data, ExtensionRegistryLite extensionRegistry)

public static Repository parseFrom(ByteBuffer data, ExtensionRegistryLite extensionRegistry)
Parameters
Name Description
data ByteBuffer
extensionRegistry ExtensionRegistryLite
Returns
Type Description
Repository
Exceptions
Type Description
InvalidProtocolBufferException

parser()

public static Parser<Repository> parser()
Returns
Type Description
Parser<Repository>

Methods

containsCleanupPolicies(String key)

public boolean containsCleanupPolicies(String key)

Optional. Cleanup policies for this repository. Cleanup policies indicate when certain package versions can be automatically deleted. Map keys are policy IDs supplied by users during policy creation. They must unique within a repository and be under 128 characters in length.

map<string, .google.devtools.artifactregistry.v1.CleanupPolicy> cleanup_policies = 12 [(.google.api.field_behavior) = OPTIONAL];

Parameter
Name Description
key String
Returns
Type Description
boolean

containsLabels(String key)

public boolean containsLabels(String key)

Labels with user-defined metadata. This field may contain up to 64 entries. Label keys and values may be no longer than 63 characters. Label keys must begin with a lowercase letter and may only contain lowercase letters, numeric characters, underscores, and dashes.

map<string, string> labels = 4;

Parameter
Name Description
key String
Returns
Type Description
boolean

equals(Object obj)

public boolean equals(Object obj)
Parameter
Name Description
obj Object
Returns
Type Description
boolean
Overrides

getCleanupPolicies() (deprecated)

public Map<String,CleanupPolicy> getCleanupPolicies()
Returns
Type Description
Map<String,CleanupPolicy>

getCleanupPoliciesCount()

public int getCleanupPoliciesCount()

Optional. Cleanup policies for this repository. Cleanup policies indicate when certain package versions can be automatically deleted. Map keys are policy IDs supplied by users during policy creation. They must unique within a repository and be under 128 characters in length.

map<string, .google.devtools.artifactregistry.v1.CleanupPolicy> cleanup_policies = 12 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
int

getCleanupPoliciesMap()

public Map<String,CleanupPolicy> getCleanupPoliciesMap()

Optional. Cleanup policies for this repository. Cleanup policies indicate when certain package versions can be automatically deleted. Map keys are policy IDs supplied by users during policy creation. They must unique within a repository and be under 128 characters in length.

map<string, .google.devtools.artifactregistry.v1.CleanupPolicy> cleanup_policies = 12 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
Map<String,CleanupPolicy>

getCleanupPoliciesOrDefault(String key, CleanupPolicy defaultValue)

public CleanupPolicy getCleanupPoliciesOrDefault(String key, CleanupPolicy defaultValue)

Optional. Cleanup policies for this repository. Cleanup policies indicate when certain package versions can be automatically deleted. Map keys are policy IDs supplied by users during policy creation. They must unique within a repository and be under 128 characters in length.

map<string, .google.devtools.artifactregistry.v1.CleanupPolicy> cleanup_policies = 12 [(.google.api.field_behavior) = OPTIONAL];

Parameters
Name Description
key String
defaultValue CleanupPolicy
Returns
Type Description
CleanupPolicy

getCleanupPoliciesOrThrow(String key)

public CleanupPolicy getCleanupPoliciesOrThrow(String key)

Optional. Cleanup policies for this repository. Cleanup policies indicate when certain package versions can be automatically deleted. Map keys are policy IDs supplied by users during policy creation. They must unique within a repository and be under 128 characters in length.

map<string, .google.devtools.artifactregistry.v1.CleanupPolicy> cleanup_policies = 12 [(.google.api.field_behavior) = OPTIONAL];

Parameter
Name Description
key String
Returns
Type Description
CleanupPolicy

getCleanupPolicyDryRun()

public boolean getCleanupPolicyDryRun()

Optional. If true, the cleanup pipeline is prevented from deleting versions in this repository.

bool cleanup_policy_dry_run = 18 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
boolean

The cleanupPolicyDryRun.

getCreateTime()

public Timestamp getCreateTime()

Output only. The time when the repository was created.

.google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY];

Returns
Type Description
Timestamp

The createTime.

getCreateTimeOrBuilder()

public TimestampOrBuilder getCreateTimeOrBuilder()

Output only. The time when the repository was created.

.google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY];

Returns
Type Description
TimestampOrBuilder

getDefaultInstanceForType()

public Repository getDefaultInstanceForType()
Returns
Type Description
Repository

getDescription()

public String getDescription()

The user-provided description of the repository.

string description = 3;

Returns
Type Description
String

The description.

getDescriptionBytes()

public ByteString getDescriptionBytes()

The user-provided description of the repository.

string description = 3;

Returns
Type Description
ByteString

The bytes for description.

getDockerConfig()

public Repository.DockerRepositoryConfig getDockerConfig()

Docker repository config contains repository level configuration for the repositories of docker type.

.google.devtools.artifactregistry.v1.Repository.DockerRepositoryConfig docker_config = 17;

Returns
Type Description
Repository.DockerRepositoryConfig

The dockerConfig.

getDockerConfigOrBuilder()

public Repository.DockerRepositoryConfigOrBuilder getDockerConfigOrBuilder()

Docker repository config contains repository level configuration for the repositories of docker type.

.google.devtools.artifactregistry.v1.Repository.DockerRepositoryConfig docker_config = 17;

Returns
Type Description
Repository.DockerRepositoryConfigOrBuilder

getFormat()

public Repository.Format getFormat()

Optional. The format of packages that are stored in the repository.

.google.devtools.artifactregistry.v1.Repository.Format format = 2 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
Repository.Format

The format.

getFormatConfigCase()

public Repository.FormatConfigCase getFormatConfigCase()
Returns
Type Description
Repository.FormatConfigCase

getFormatValue()

public int getFormatValue()

Optional. The format of packages that are stored in the repository.

.google.devtools.artifactregistry.v1.Repository.Format format = 2 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
int

The enum numeric value on the wire for format.

getKmsKeyName()

public String getKmsKeyName()

The Cloud KMS resource name of the customer managed encryption key that's used to encrypt the contents of the Repository. Has the form: projects/my-project/locations/my-region/keyRings/my-kr/cryptoKeys/my-key. This value may not be changed after the Repository has been created.

string kms_key_name = 8;

Returns
Type Description
String

The kmsKeyName.

getKmsKeyNameBytes()

public ByteString getKmsKeyNameBytes()

The Cloud KMS resource name of the customer managed encryption key that's used to encrypt the contents of the Repository. Has the form: projects/my-project/locations/my-region/keyRings/my-kr/cryptoKeys/my-key. This value may not be changed after the Repository has been created.

string kms_key_name = 8;

Returns
Type Description
ByteString

The bytes for kmsKeyName.

getLabels() (deprecated)

public Map<String,String> getLabels()

Use #getLabelsMap() instead.

Returns
Type Description
Map<String,String>

getLabelsCount()

public int getLabelsCount()

Labels with user-defined metadata. This field may contain up to 64 entries. Label keys and values may be no longer than 63 characters. Label keys must begin with a lowercase letter and may only contain lowercase letters, numeric characters, underscores, and dashes.

map<string, string> labels = 4;

Returns
Type Description
int

getLabelsMap()

public Map<String,String> getLabelsMap()

Labels with user-defined metadata. This field may contain up to 64 entries. Label keys and values may be no longer than 63 characters. Label keys must begin with a lowercase letter and may only contain lowercase letters, numeric characters, underscores, and dashes.

map<string, string> labels = 4;

Returns
Type Description
Map<String,String>

getLabelsOrDefault(String key, String defaultValue)

public String getLabelsOrDefault(String key, String defaultValue)

Labels with user-defined metadata. This field may contain up to 64 entries. Label keys and values may be no longer than 63 characters. Label keys must begin with a lowercase letter and may only contain lowercase letters, numeric characters, underscores, and dashes.

map<string, string> labels = 4;

Parameters
Name Description
key String
defaultValue String
Returns
Type Description
String

getLabelsOrThrow(String key)

public String getLabelsOrThrow(String key)

Labels with user-defined metadata. This field may contain up to 64 entries. Label keys and values may be no longer than 63 characters. Label keys must begin with a lowercase letter and may only contain lowercase letters, numeric characters, underscores, and dashes.

map<string, string> labels = 4;

Parameter
Name Description
key String
Returns
Type Description
String

getMavenConfig()

public Repository.MavenRepositoryConfig getMavenConfig()

Maven repository config contains repository level configuration for the repositories of maven type.

.google.devtools.artifactregistry.v1.Repository.MavenRepositoryConfig maven_config = 9;

Returns
Type Description
Repository.MavenRepositoryConfig

The mavenConfig.

getMavenConfigOrBuilder()

public Repository.MavenRepositoryConfigOrBuilder getMavenConfigOrBuilder()

Maven repository config contains repository level configuration for the repositories of maven type.

.google.devtools.artifactregistry.v1.Repository.MavenRepositoryConfig maven_config = 9;

Returns
Type Description
Repository.MavenRepositoryConfigOrBuilder

getMode()

public Repository.Mode getMode()

Optional. The mode of the repository.

.google.devtools.artifactregistry.v1.Repository.Mode mode = 10 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
Repository.Mode

The mode.

getModeConfigCase()

public Repository.ModeConfigCase getModeConfigCase()
Returns
Type Description
Repository.ModeConfigCase

getModeValue()

public int getModeValue()

Optional. The mode of the repository.

.google.devtools.artifactregistry.v1.Repository.Mode mode = 10 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
int

The enum numeric value on the wire for mode.

getName()

public String getName()

The name of the repository, for example: projects/p1/locations/us-central1/repositories/repo1.

string name = 1;

Returns
Type Description
String

The name.

getNameBytes()

public ByteString getNameBytes()

The name of the repository, for example: projects/p1/locations/us-central1/repositories/repo1.

string name = 1;

Returns
Type Description
ByteString

The bytes for name.

getParserForType()

public Parser<Repository> getParserForType()
Returns
Type Description
Parser<Repository>
Overrides

getRemoteRepositoryConfig()

public RemoteRepositoryConfig getRemoteRepositoryConfig()

Configuration specific for a Remote Repository.

.google.devtools.artifactregistry.v1.RemoteRepositoryConfig remote_repository_config = 15;

Returns
Type Description
RemoteRepositoryConfig

The remoteRepositoryConfig.

getRemoteRepositoryConfigOrBuilder()

public RemoteRepositoryConfigOrBuilder getRemoteRepositoryConfigOrBuilder()

Configuration specific for a Remote Repository.

.google.devtools.artifactregistry.v1.RemoteRepositoryConfig remote_repository_config = 15;

Returns
Type Description
RemoteRepositoryConfigOrBuilder

getSatisfiesPzs()

public boolean getSatisfiesPzs()

Output only. If set, the repository satisfies physical zone separation.

bool satisfies_pzs = 16 [(.google.api.field_behavior) = OUTPUT_ONLY];

Returns
Type Description
boolean

The satisfiesPzs.

getSerializedSize()

public int getSerializedSize()
Returns
Type Description
int
Overrides

getSizeBytes()

public long getSizeBytes()

Output only. The size, in bytes, of all artifact storage in this repository. Repositories that are generally available or in public preview use this to calculate storage costs.

int64 size_bytes = 13 [(.google.api.field_behavior) = OUTPUT_ONLY];

Returns
Type Description
long

The sizeBytes.

getUpdateTime()

public Timestamp getUpdateTime()

Output only. The time when the repository was last updated.

.google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY];

Returns
Type Description
Timestamp

The updateTime.

getUpdateTimeOrBuilder()

public TimestampOrBuilder getUpdateTimeOrBuilder()

Output only. The time when the repository was last updated.

.google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY];

Returns
Type Description
TimestampOrBuilder

getVirtualRepositoryConfig()

public VirtualRepositoryConfig getVirtualRepositoryConfig()

Configuration specific for a Virtual Repository.

.google.devtools.artifactregistry.v1.VirtualRepositoryConfig virtual_repository_config = 14;

Returns
Type Description
VirtualRepositoryConfig

The virtualRepositoryConfig.

getVirtualRepositoryConfigOrBuilder()

public VirtualRepositoryConfigOrBuilder getVirtualRepositoryConfigOrBuilder()

Configuration specific for a Virtual Repository.

.google.devtools.artifactregistry.v1.VirtualRepositoryConfig virtual_repository_config = 14;

Returns
Type Description
VirtualRepositoryConfigOrBuilder

hasCreateTime()

public boolean hasCreateTime()

Output only. The time when the repository was created.

.google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY];

Returns
Type Description
boolean

Whether the createTime field is set.

hasDockerConfig()

public boolean hasDockerConfig()

Docker repository config contains repository level configuration for the repositories of docker type.

.google.devtools.artifactregistry.v1.Repository.DockerRepositoryConfig docker_config = 17;

Returns
Type Description
boolean

Whether the dockerConfig field is set.

hasMavenConfig()

public boolean hasMavenConfig()

Maven repository config contains repository level configuration for the repositories of maven type.

.google.devtools.artifactregistry.v1.Repository.MavenRepositoryConfig maven_config = 9;

Returns
Type Description
boolean

Whether the mavenConfig field is set.

hasRemoteRepositoryConfig()

public boolean hasRemoteRepositoryConfig()

Configuration specific for a Remote Repository.

.google.devtools.artifactregistry.v1.RemoteRepositoryConfig remote_repository_config = 15;

Returns
Type Description
boolean

Whether the remoteRepositoryConfig field is set.

hasUpdateTime()

public boolean hasUpdateTime()

Output only. The time when the repository was last updated.

.google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY];

Returns
Type Description
boolean

Whether the updateTime field is set.

hasVirtualRepositoryConfig()

public boolean hasVirtualRepositoryConfig()

Configuration specific for a Virtual Repository.

.google.devtools.artifactregistry.v1.VirtualRepositoryConfig virtual_repository_config = 14;

Returns
Type Description
boolean

Whether the virtualRepositoryConfig field is set.

hashCode()

public int hashCode()
Returns
Type Description
int
Overrides

internalGetFieldAccessorTable()

protected GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
Returns
Type Description
FieldAccessorTable
Overrides

internalGetMapFieldReflection(int number)

protected MapFieldReflectionAccessor internalGetMapFieldReflection(int number)
Parameter
Name Description
number int
Returns
Type Description
com.google.protobuf.MapFieldReflectionAccessor
Overrides
com.google.protobuf.GeneratedMessageV3.internalGetMapFieldReflection(int)

isInitialized()

public final boolean isInitialized()
Returns
Type Description
boolean
Overrides

newBuilderForType()

public Repository.Builder newBuilderForType()
Returns
Type Description
Repository.Builder

newBuilderForType(GeneratedMessageV3.BuilderParent parent)

protected Repository.Builder newBuilderForType(GeneratedMessageV3.BuilderParent parent)
Parameter
Name Description
parent BuilderParent
Returns
Type Description
Repository.Builder
Overrides

newInstance(GeneratedMessageV3.UnusedPrivateParameter unused)

protected Object newInstance(GeneratedMessageV3.UnusedPrivateParameter unused)
Parameter
Name Description
unused UnusedPrivateParameter
Returns
Type Description
Object
Overrides

toBuilder()

public Repository.Builder toBuilder()
Returns
Type Description
Repository.Builder

writeTo(CodedOutputStream output)

public void writeTo(CodedOutputStream output)
Parameter
Name Description
output CodedOutputStream
Overrides
Exceptions
Type Description
IOException