Class AuditLogConfig.Builder (1.14.0)

public static final class AuditLogConfig.Builder extends GeneratedMessageV3.Builder<AuditLogConfig.Builder> implements AuditLogConfigOrBuilder

Provides the configuration for logging a type of permissions. Example: { "audit_log_configs": [ { "log_type": "DATA_READ", "exempted_members": [ "user:jose@example.com" ] }, { "log_type": "DATA_WRITE" } ] } This enables 'DATA_READ' and 'DATA_WRITE' logging, while exempting jose@example.com from DATA_READ logging.

Protobuf type google.cloud.compute.v1.AuditLogConfig

Static Methods

getDescriptor()

public static final Descriptors.Descriptor getDescriptor()
Returns
TypeDescription
Descriptor

Methods

addAllExemptedMembers(Iterable<String> values)

public AuditLogConfig.Builder addAllExemptedMembers(Iterable<String> values)

Specifies the identities that do not cause logging for this type of permission. Follows the same format of Binding.members.

repeated string exempted_members = 232615576;

Parameter
NameDescription
valuesIterable<String>

The exemptedMembers to add.

Returns
TypeDescription
AuditLogConfig.Builder

This builder for chaining.

addExemptedMembers(String value)

public AuditLogConfig.Builder addExemptedMembers(String value)

Specifies the identities that do not cause logging for this type of permission. Follows the same format of Binding.members.

repeated string exempted_members = 232615576;

Parameter
NameDescription
valueString

The exemptedMembers to add.

Returns
TypeDescription
AuditLogConfig.Builder

This builder for chaining.

addExemptedMembersBytes(ByteString value)

public AuditLogConfig.Builder addExemptedMembersBytes(ByteString value)

Specifies the identities that do not cause logging for this type of permission. Follows the same format of Binding.members.

repeated string exempted_members = 232615576;

Parameter
NameDescription
valueByteString

The bytes of the exemptedMembers to add.

Returns
TypeDescription
AuditLogConfig.Builder

This builder for chaining.

addRepeatedField(Descriptors.FieldDescriptor field, Object value)

public AuditLogConfig.Builder addRepeatedField(Descriptors.FieldDescriptor field, Object value)
Parameters
NameDescription
fieldFieldDescriptor
valueObject
Returns
TypeDescription
AuditLogConfig.Builder
Overrides

build()

public AuditLogConfig build()
Returns
TypeDescription
AuditLogConfig

buildPartial()

public AuditLogConfig buildPartial()
Returns
TypeDescription
AuditLogConfig

clear()

public AuditLogConfig.Builder clear()
Returns
TypeDescription
AuditLogConfig.Builder
Overrides

clearExemptedMembers()

public AuditLogConfig.Builder clearExemptedMembers()

Specifies the identities that do not cause logging for this type of permission. Follows the same format of Binding.members.

repeated string exempted_members = 232615576;

Returns
TypeDescription
AuditLogConfig.Builder

This builder for chaining.

clearField(Descriptors.FieldDescriptor field)

public AuditLogConfig.Builder clearField(Descriptors.FieldDescriptor field)
Parameter
NameDescription
fieldFieldDescriptor
Returns
TypeDescription
AuditLogConfig.Builder
Overrides

clearIgnoreChildExemptions()

public AuditLogConfig.Builder clearIgnoreChildExemptions()

This is deprecated and has no effect. Do not use.

optional bool ignore_child_exemptions = 70141850;

Returns
TypeDescription
AuditLogConfig.Builder

This builder for chaining.

clearLogType()

public AuditLogConfig.Builder clearLogType()

The log type that this config enables. Check the LogType enum for the list of possible values.

optional string log_type = 403115861;

Returns
TypeDescription
AuditLogConfig.Builder

This builder for chaining.

clearOneof(Descriptors.OneofDescriptor oneof)

public AuditLogConfig.Builder clearOneof(Descriptors.OneofDescriptor oneof)
Parameter
NameDescription
oneofOneofDescriptor
Returns
TypeDescription
AuditLogConfig.Builder
Overrides

clone()

public AuditLogConfig.Builder clone()
Returns
TypeDescription
AuditLogConfig.Builder
Overrides

getDefaultInstanceForType()

public AuditLogConfig getDefaultInstanceForType()
Returns
TypeDescription
AuditLogConfig

getDescriptorForType()

public Descriptors.Descriptor getDescriptorForType()
Returns
TypeDescription
Descriptor
Overrides

getExemptedMembers(int index)

public String getExemptedMembers(int index)

Specifies the identities that do not cause logging for this type of permission. Follows the same format of Binding.members.

repeated string exempted_members = 232615576;

Parameter
NameDescription
indexint

The index of the element to return.

Returns
TypeDescription
String

The exemptedMembers at the given index.

getExemptedMembersBytes(int index)

public ByteString getExemptedMembersBytes(int index)

Specifies the identities that do not cause logging for this type of permission. Follows the same format of Binding.members.

repeated string exempted_members = 232615576;

Parameter
NameDescription
indexint

The index of the value to return.

Returns
TypeDescription
ByteString

The bytes of the exemptedMembers at the given index.

getExemptedMembersCount()

public int getExemptedMembersCount()

Specifies the identities that do not cause logging for this type of permission. Follows the same format of Binding.members.

repeated string exempted_members = 232615576;

Returns
TypeDescription
int

The count of exemptedMembers.

getExemptedMembersList()

public ProtocolStringList getExemptedMembersList()

Specifies the identities that do not cause logging for this type of permission. Follows the same format of Binding.members.

repeated string exempted_members = 232615576;

Returns
TypeDescription
ProtocolStringList

A list containing the exemptedMembers.

getIgnoreChildExemptions()

public boolean getIgnoreChildExemptions()

This is deprecated and has no effect. Do not use.

optional bool ignore_child_exemptions = 70141850;

Returns
TypeDescription
boolean

The ignoreChildExemptions.

getLogType()

public String getLogType()

The log type that this config enables. Check the LogType enum for the list of possible values.

optional string log_type = 403115861;

Returns
TypeDescription
String

The logType.

getLogTypeBytes()

public ByteString getLogTypeBytes()

The log type that this config enables. Check the LogType enum for the list of possible values.

optional string log_type = 403115861;

Returns
TypeDescription
ByteString

The bytes for logType.

hasIgnoreChildExemptions()

public boolean hasIgnoreChildExemptions()

This is deprecated and has no effect. Do not use.

optional bool ignore_child_exemptions = 70141850;

Returns
TypeDescription
boolean

Whether the ignoreChildExemptions field is set.

hasLogType()

public boolean hasLogType()

The log type that this config enables. Check the LogType enum for the list of possible values.

optional string log_type = 403115861;

Returns
TypeDescription
boolean

Whether the logType field is set.

internalGetFieldAccessorTable()

protected GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
Returns
TypeDescription
FieldAccessorTable
Overrides

isInitialized()

public final boolean isInitialized()
Returns
TypeDescription
boolean
Overrides

mergeFrom(AuditLogConfig other)

public AuditLogConfig.Builder mergeFrom(AuditLogConfig other)
Parameter
NameDescription
otherAuditLogConfig
Returns
TypeDescription
AuditLogConfig.Builder

mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)

public AuditLogConfig.Builder mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)
Parameters
NameDescription
inputCodedInputStream
extensionRegistryExtensionRegistryLite
Returns
TypeDescription
AuditLogConfig.Builder
Overrides Exceptions
TypeDescription
IOException

mergeFrom(Message other)

public AuditLogConfig.Builder mergeFrom(Message other)
Parameter
NameDescription
otherMessage
Returns
TypeDescription
AuditLogConfig.Builder
Overrides

mergeUnknownFields(UnknownFieldSet unknownFields)

public final AuditLogConfig.Builder mergeUnknownFields(UnknownFieldSet unknownFields)
Parameter
NameDescription
unknownFieldsUnknownFieldSet
Returns
TypeDescription
AuditLogConfig.Builder
Overrides

setExemptedMembers(int index, String value)

public AuditLogConfig.Builder setExemptedMembers(int index, String value)

Specifies the identities that do not cause logging for this type of permission. Follows the same format of Binding.members.

repeated string exempted_members = 232615576;

Parameters
NameDescription
indexint

The index to set the value at.

valueString

The exemptedMembers to set.

Returns
TypeDescription
AuditLogConfig.Builder

This builder for chaining.

setField(Descriptors.FieldDescriptor field, Object value)

public AuditLogConfig.Builder setField(Descriptors.FieldDescriptor field, Object value)
Parameters
NameDescription
fieldFieldDescriptor
valueObject
Returns
TypeDescription
AuditLogConfig.Builder
Overrides

setIgnoreChildExemptions(boolean value)

public AuditLogConfig.Builder setIgnoreChildExemptions(boolean value)

This is deprecated and has no effect. Do not use.

optional bool ignore_child_exemptions = 70141850;

Parameter
NameDescription
valueboolean

The ignoreChildExemptions to set.

Returns
TypeDescription
AuditLogConfig.Builder

This builder for chaining.

setLogType(String value)

public AuditLogConfig.Builder setLogType(String value)

The log type that this config enables. Check the LogType enum for the list of possible values.

optional string log_type = 403115861;

Parameter
NameDescription
valueString

The logType to set.

Returns
TypeDescription
AuditLogConfig.Builder

This builder for chaining.

setLogTypeBytes(ByteString value)

public AuditLogConfig.Builder setLogTypeBytes(ByteString value)

The log type that this config enables. Check the LogType enum for the list of possible values.

optional string log_type = 403115861;

Parameter
NameDescription
valueByteString

The bytes for logType to set.

Returns
TypeDescription
AuditLogConfig.Builder

This builder for chaining.

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

public AuditLogConfig.Builder setRepeatedField(Descriptors.FieldDescriptor field, int index, Object value)
Parameters
NameDescription
fieldFieldDescriptor
indexint
valueObject
Returns
TypeDescription
AuditLogConfig.Builder
Overrides

setUnknownFields(UnknownFieldSet unknownFields)

public final AuditLogConfig.Builder setUnknownFields(UnknownFieldSet unknownFields)
Parameter
NameDescription
unknownFieldsUnknownFieldSet
Returns
TypeDescription
AuditLogConfig.Builder
Overrides