Class KeyUsage.Builder (2.48.0)

public static final class KeyUsage.Builder extends GeneratedMessageV3.Builder<KeyUsage.Builder> implements KeyUsageOrBuilder

A KeyUsage describes key usage values that may appear in an X.509 certificate.

Protobuf type google.cloud.security.privateca.v1.KeyUsage

Implements

KeyUsageOrBuilder

Static Methods

getDescriptor()

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

Methods

addAllUnknownExtendedKeyUsages(Iterable<? extends ObjectId> values)

public KeyUsage.Builder addAllUnknownExtendedKeyUsages(Iterable<? extends ObjectId> values)

Used to describe extended key usages that are not listed in the KeyUsage.ExtendedKeyUsageOptions message.

repeated .google.cloud.security.privateca.v1.ObjectId unknown_extended_key_usages = 3;

Parameter
Name Description
values Iterable<? extends com.google.cloud.security.privateca.v1.ObjectId>
Returns
Type Description
KeyUsage.Builder

addRepeatedField(Descriptors.FieldDescriptor field, Object value)

public KeyUsage.Builder addRepeatedField(Descriptors.FieldDescriptor field, Object value)
Parameters
Name Description
field FieldDescriptor
value Object
Returns
Type Description
KeyUsage.Builder
Overrides

addUnknownExtendedKeyUsages(ObjectId value)

public KeyUsage.Builder addUnknownExtendedKeyUsages(ObjectId value)

Used to describe extended key usages that are not listed in the KeyUsage.ExtendedKeyUsageOptions message.

repeated .google.cloud.security.privateca.v1.ObjectId unknown_extended_key_usages = 3;

Parameter
Name Description
value ObjectId
Returns
Type Description
KeyUsage.Builder

addUnknownExtendedKeyUsages(ObjectId.Builder builderForValue)

public KeyUsage.Builder addUnknownExtendedKeyUsages(ObjectId.Builder builderForValue)

Used to describe extended key usages that are not listed in the KeyUsage.ExtendedKeyUsageOptions message.

repeated .google.cloud.security.privateca.v1.ObjectId unknown_extended_key_usages = 3;

Parameter
Name Description
builderForValue ObjectId.Builder
Returns
Type Description
KeyUsage.Builder

addUnknownExtendedKeyUsages(int index, ObjectId value)

public KeyUsage.Builder addUnknownExtendedKeyUsages(int index, ObjectId value)

Used to describe extended key usages that are not listed in the KeyUsage.ExtendedKeyUsageOptions message.

repeated .google.cloud.security.privateca.v1.ObjectId unknown_extended_key_usages = 3;

Parameters
Name Description
index int
value ObjectId
Returns
Type Description
KeyUsage.Builder

addUnknownExtendedKeyUsages(int index, ObjectId.Builder builderForValue)

public KeyUsage.Builder addUnknownExtendedKeyUsages(int index, ObjectId.Builder builderForValue)

Used to describe extended key usages that are not listed in the KeyUsage.ExtendedKeyUsageOptions message.

repeated .google.cloud.security.privateca.v1.ObjectId unknown_extended_key_usages = 3;

Parameters
Name Description
index int
builderForValue ObjectId.Builder
Returns
Type Description
KeyUsage.Builder

addUnknownExtendedKeyUsagesBuilder()

public ObjectId.Builder addUnknownExtendedKeyUsagesBuilder()

Used to describe extended key usages that are not listed in the KeyUsage.ExtendedKeyUsageOptions message.

repeated .google.cloud.security.privateca.v1.ObjectId unknown_extended_key_usages = 3;

Returns
Type Description
ObjectId.Builder

addUnknownExtendedKeyUsagesBuilder(int index)

public ObjectId.Builder addUnknownExtendedKeyUsagesBuilder(int index)

Used to describe extended key usages that are not listed in the KeyUsage.ExtendedKeyUsageOptions message.

repeated .google.cloud.security.privateca.v1.ObjectId unknown_extended_key_usages = 3;

Parameter
Name Description
index int
Returns
Type Description
ObjectId.Builder

build()

public KeyUsage build()
Returns
Type Description
KeyUsage

buildPartial()

public KeyUsage buildPartial()
Returns
Type Description
KeyUsage

clear()

public KeyUsage.Builder clear()
Returns
Type Description
KeyUsage.Builder
Overrides

clearBaseKeyUsage()

public KeyUsage.Builder clearBaseKeyUsage()

Describes high-level ways in which a key may be used.

.google.cloud.security.privateca.v1.KeyUsage.KeyUsageOptions base_key_usage = 1;

Returns
Type Description
KeyUsage.Builder

clearExtendedKeyUsage()

public KeyUsage.Builder clearExtendedKeyUsage()

Detailed scenarios in which a key may be used.

.google.cloud.security.privateca.v1.KeyUsage.ExtendedKeyUsageOptions extended_key_usage = 2;

Returns
Type Description
KeyUsage.Builder

clearField(Descriptors.FieldDescriptor field)

public KeyUsage.Builder clearField(Descriptors.FieldDescriptor field)
Parameter
Name Description
field FieldDescriptor
Returns
Type Description
KeyUsage.Builder
Overrides

clearOneof(Descriptors.OneofDescriptor oneof)

public KeyUsage.Builder clearOneof(Descriptors.OneofDescriptor oneof)
Parameter
Name Description
oneof OneofDescriptor
Returns
Type Description
KeyUsage.Builder
Overrides

clearUnknownExtendedKeyUsages()

public KeyUsage.Builder clearUnknownExtendedKeyUsages()

Used to describe extended key usages that are not listed in the KeyUsage.ExtendedKeyUsageOptions message.

repeated .google.cloud.security.privateca.v1.ObjectId unknown_extended_key_usages = 3;

Returns
Type Description
KeyUsage.Builder

clone()

public KeyUsage.Builder clone()
Returns
Type Description
KeyUsage.Builder
Overrides

getBaseKeyUsage()

public KeyUsage.KeyUsageOptions getBaseKeyUsage()

Describes high-level ways in which a key may be used.

.google.cloud.security.privateca.v1.KeyUsage.KeyUsageOptions base_key_usage = 1;

Returns
Type Description
KeyUsage.KeyUsageOptions

The baseKeyUsage.

getBaseKeyUsageBuilder()

public KeyUsage.KeyUsageOptions.Builder getBaseKeyUsageBuilder()

Describes high-level ways in which a key may be used.

.google.cloud.security.privateca.v1.KeyUsage.KeyUsageOptions base_key_usage = 1;

Returns
Type Description
KeyUsage.KeyUsageOptions.Builder

getBaseKeyUsageOrBuilder()

public KeyUsage.KeyUsageOptionsOrBuilder getBaseKeyUsageOrBuilder()

Describes high-level ways in which a key may be used.

.google.cloud.security.privateca.v1.KeyUsage.KeyUsageOptions base_key_usage = 1;

Returns
Type Description
KeyUsage.KeyUsageOptionsOrBuilder

getDefaultInstanceForType()

public KeyUsage getDefaultInstanceForType()
Returns
Type Description
KeyUsage

getDescriptorForType()

public Descriptors.Descriptor getDescriptorForType()
Returns
Type Description
Descriptor
Overrides

getExtendedKeyUsage()

public KeyUsage.ExtendedKeyUsageOptions getExtendedKeyUsage()

Detailed scenarios in which a key may be used.

.google.cloud.security.privateca.v1.KeyUsage.ExtendedKeyUsageOptions extended_key_usage = 2;

Returns
Type Description
KeyUsage.ExtendedKeyUsageOptions

The extendedKeyUsage.

getExtendedKeyUsageBuilder()

public KeyUsage.ExtendedKeyUsageOptions.Builder getExtendedKeyUsageBuilder()

Detailed scenarios in which a key may be used.

.google.cloud.security.privateca.v1.KeyUsage.ExtendedKeyUsageOptions extended_key_usage = 2;

Returns
Type Description
KeyUsage.ExtendedKeyUsageOptions.Builder

getExtendedKeyUsageOrBuilder()

public KeyUsage.ExtendedKeyUsageOptionsOrBuilder getExtendedKeyUsageOrBuilder()

Detailed scenarios in which a key may be used.

.google.cloud.security.privateca.v1.KeyUsage.ExtendedKeyUsageOptions extended_key_usage = 2;

Returns
Type Description
KeyUsage.ExtendedKeyUsageOptionsOrBuilder

getUnknownExtendedKeyUsages(int index)

public ObjectId getUnknownExtendedKeyUsages(int index)

Used to describe extended key usages that are not listed in the KeyUsage.ExtendedKeyUsageOptions message.

repeated .google.cloud.security.privateca.v1.ObjectId unknown_extended_key_usages = 3;

Parameter
Name Description
index int
Returns
Type Description
ObjectId

getUnknownExtendedKeyUsagesBuilder(int index)

public ObjectId.Builder getUnknownExtendedKeyUsagesBuilder(int index)

Used to describe extended key usages that are not listed in the KeyUsage.ExtendedKeyUsageOptions message.

repeated .google.cloud.security.privateca.v1.ObjectId unknown_extended_key_usages = 3;

Parameter
Name Description
index int
Returns
Type Description
ObjectId.Builder

getUnknownExtendedKeyUsagesBuilderList()

public List<ObjectId.Builder> getUnknownExtendedKeyUsagesBuilderList()

Used to describe extended key usages that are not listed in the KeyUsage.ExtendedKeyUsageOptions message.

repeated .google.cloud.security.privateca.v1.ObjectId unknown_extended_key_usages = 3;

Returns
Type Description
List<Builder>

getUnknownExtendedKeyUsagesCount()

public int getUnknownExtendedKeyUsagesCount()

Used to describe extended key usages that are not listed in the KeyUsage.ExtendedKeyUsageOptions message.

repeated .google.cloud.security.privateca.v1.ObjectId unknown_extended_key_usages = 3;

Returns
Type Description
int

getUnknownExtendedKeyUsagesList()

public List<ObjectId> getUnknownExtendedKeyUsagesList()

Used to describe extended key usages that are not listed in the KeyUsage.ExtendedKeyUsageOptions message.

repeated .google.cloud.security.privateca.v1.ObjectId unknown_extended_key_usages = 3;

Returns
Type Description
List<ObjectId>

getUnknownExtendedKeyUsagesOrBuilder(int index)

public ObjectIdOrBuilder getUnknownExtendedKeyUsagesOrBuilder(int index)

Used to describe extended key usages that are not listed in the KeyUsage.ExtendedKeyUsageOptions message.

repeated .google.cloud.security.privateca.v1.ObjectId unknown_extended_key_usages = 3;

Parameter
Name Description
index int
Returns
Type Description
ObjectIdOrBuilder

getUnknownExtendedKeyUsagesOrBuilderList()

public List<? extends ObjectIdOrBuilder> getUnknownExtendedKeyUsagesOrBuilderList()

Used to describe extended key usages that are not listed in the KeyUsage.ExtendedKeyUsageOptions message.

repeated .google.cloud.security.privateca.v1.ObjectId unknown_extended_key_usages = 3;

Returns
Type Description
List<? extends com.google.cloud.security.privateca.v1.ObjectIdOrBuilder>

hasBaseKeyUsage()

public boolean hasBaseKeyUsage()

Describes high-level ways in which a key may be used.

.google.cloud.security.privateca.v1.KeyUsage.KeyUsageOptions base_key_usage = 1;

Returns
Type Description
boolean

Whether the baseKeyUsage field is set.

hasExtendedKeyUsage()

public boolean hasExtendedKeyUsage()

Detailed scenarios in which a key may be used.

.google.cloud.security.privateca.v1.KeyUsage.ExtendedKeyUsageOptions extended_key_usage = 2;

Returns
Type Description
boolean

Whether the extendedKeyUsage field is set.

internalGetFieldAccessorTable()

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

isInitialized()

public final boolean isInitialized()
Returns
Type Description
boolean
Overrides

mergeBaseKeyUsage(KeyUsage.KeyUsageOptions value)

public KeyUsage.Builder mergeBaseKeyUsage(KeyUsage.KeyUsageOptions value)

Describes high-level ways in which a key may be used.

.google.cloud.security.privateca.v1.KeyUsage.KeyUsageOptions base_key_usage = 1;

Parameter
Name Description
value KeyUsage.KeyUsageOptions
Returns
Type Description
KeyUsage.Builder

mergeExtendedKeyUsage(KeyUsage.ExtendedKeyUsageOptions value)

public KeyUsage.Builder mergeExtendedKeyUsage(KeyUsage.ExtendedKeyUsageOptions value)

Detailed scenarios in which a key may be used.

.google.cloud.security.privateca.v1.KeyUsage.ExtendedKeyUsageOptions extended_key_usage = 2;

Parameter
Name Description
value KeyUsage.ExtendedKeyUsageOptions
Returns
Type Description
KeyUsage.Builder

mergeFrom(KeyUsage other)

public KeyUsage.Builder mergeFrom(KeyUsage other)
Parameter
Name Description
other KeyUsage
Returns
Type Description
KeyUsage.Builder

mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)

public KeyUsage.Builder mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)
Parameters
Name Description
input CodedInputStream
extensionRegistry ExtensionRegistryLite
Returns
Type Description
KeyUsage.Builder
Overrides
Exceptions
Type Description
IOException

mergeFrom(Message other)

public KeyUsage.Builder mergeFrom(Message other)
Parameter
Name Description
other Message
Returns
Type Description
KeyUsage.Builder
Overrides

mergeUnknownFields(UnknownFieldSet unknownFields)

public final KeyUsage.Builder mergeUnknownFields(UnknownFieldSet unknownFields)
Parameter
Name Description
unknownFields UnknownFieldSet
Returns
Type Description
KeyUsage.Builder
Overrides

removeUnknownExtendedKeyUsages(int index)

public KeyUsage.Builder removeUnknownExtendedKeyUsages(int index)

Used to describe extended key usages that are not listed in the KeyUsage.ExtendedKeyUsageOptions message.

repeated .google.cloud.security.privateca.v1.ObjectId unknown_extended_key_usages = 3;

Parameter
Name Description
index int
Returns
Type Description
KeyUsage.Builder

setBaseKeyUsage(KeyUsage.KeyUsageOptions value)

public KeyUsage.Builder setBaseKeyUsage(KeyUsage.KeyUsageOptions value)

Describes high-level ways in which a key may be used.

.google.cloud.security.privateca.v1.KeyUsage.KeyUsageOptions base_key_usage = 1;

Parameter
Name Description
value KeyUsage.KeyUsageOptions
Returns
Type Description
KeyUsage.Builder

setBaseKeyUsage(KeyUsage.KeyUsageOptions.Builder builderForValue)

public KeyUsage.Builder setBaseKeyUsage(KeyUsage.KeyUsageOptions.Builder builderForValue)

Describes high-level ways in which a key may be used.

.google.cloud.security.privateca.v1.KeyUsage.KeyUsageOptions base_key_usage = 1;

Parameter
Name Description
builderForValue KeyUsage.KeyUsageOptions.Builder
Returns
Type Description
KeyUsage.Builder

setExtendedKeyUsage(KeyUsage.ExtendedKeyUsageOptions value)

public KeyUsage.Builder setExtendedKeyUsage(KeyUsage.ExtendedKeyUsageOptions value)

Detailed scenarios in which a key may be used.

.google.cloud.security.privateca.v1.KeyUsage.ExtendedKeyUsageOptions extended_key_usage = 2;

Parameter
Name Description
value KeyUsage.ExtendedKeyUsageOptions
Returns
Type Description
KeyUsage.Builder

setExtendedKeyUsage(KeyUsage.ExtendedKeyUsageOptions.Builder builderForValue)

public KeyUsage.Builder setExtendedKeyUsage(KeyUsage.ExtendedKeyUsageOptions.Builder builderForValue)

Detailed scenarios in which a key may be used.

.google.cloud.security.privateca.v1.KeyUsage.ExtendedKeyUsageOptions extended_key_usage = 2;

Parameter
Name Description
builderForValue KeyUsage.ExtendedKeyUsageOptions.Builder
Returns
Type Description
KeyUsage.Builder

setField(Descriptors.FieldDescriptor field, Object value)

public KeyUsage.Builder setField(Descriptors.FieldDescriptor field, Object value)
Parameters
Name Description
field FieldDescriptor
value Object
Returns
Type Description
KeyUsage.Builder
Overrides

setRepeatedField(Descriptors.FieldDescriptor field, int index, Object value)

public KeyUsage.Builder setRepeatedField(Descriptors.FieldDescriptor field, int index, Object value)
Parameters
Name Description
field FieldDescriptor
index int
value Object
Returns
Type Description
KeyUsage.Builder
Overrides

setUnknownExtendedKeyUsages(int index, ObjectId value)

public KeyUsage.Builder setUnknownExtendedKeyUsages(int index, ObjectId value)

Used to describe extended key usages that are not listed in the KeyUsage.ExtendedKeyUsageOptions message.

repeated .google.cloud.security.privateca.v1.ObjectId unknown_extended_key_usages = 3;

Parameters
Name Description
index int
value ObjectId
Returns
Type Description
KeyUsage.Builder

setUnknownExtendedKeyUsages(int index, ObjectId.Builder builderForValue)

public KeyUsage.Builder setUnknownExtendedKeyUsages(int index, ObjectId.Builder builderForValue)

Used to describe extended key usages that are not listed in the KeyUsage.ExtendedKeyUsageOptions message.

repeated .google.cloud.security.privateca.v1.ObjectId unknown_extended_key_usages = 3;

Parameters
Name Description
index int
builderForValue ObjectId.Builder
Returns
Type Description
KeyUsage.Builder

setUnknownFields(UnknownFieldSet unknownFields)

public final KeyUsage.Builder setUnknownFields(UnknownFieldSet unknownFields)
Parameter
Name Description
unknownFields UnknownFieldSet
Returns
Type Description
KeyUsage.Builder
Overrides