Class AuditLogConfig.Builder (1.93.0)

public static final class AuditLogConfig.Builder extends GeneratedMessage.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
Type Description
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
Name Description
values Iterable<String>

The exemptedMembers to add.

Returns
Type Description
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
Name Description
value String

The exemptedMembers to add.

Returns
Type Description
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
Name Description
value ByteString

The bytes of the exemptedMembers to add.

Returns
Type Description
AuditLogConfig.Builder

This builder for chaining.

build()

public AuditLogConfig build()
Returns
Type Description
AuditLogConfig

buildPartial()

public AuditLogConfig buildPartial()
Returns
Type Description
AuditLogConfig

clear()

public AuditLogConfig.Builder clear()
Returns
Type Description
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
Type Description
AuditLogConfig.Builder

This builder for chaining.

clearIgnoreChildExemptions()

public AuditLogConfig.Builder clearIgnoreChildExemptions()

optional bool ignore_child_exemptions = 70141850;

Returns
Type Description
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
Type Description
AuditLogConfig.Builder

This builder for chaining.

getDefaultInstanceForType()

public AuditLogConfig getDefaultInstanceForType()
Returns
Type Description
AuditLogConfig

getDescriptorForType()

public Descriptors.Descriptor getDescriptorForType()
Returns
Type Description
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
Name Description
index int

The index of the element to return.

Returns
Type Description
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
Name Description
index int

The index of the value to return.

Returns
Type Description
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
Type Description
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
Type Description
ProtocolStringList

A list containing the exemptedMembers.

getIgnoreChildExemptions()

public boolean getIgnoreChildExemptions()

optional bool ignore_child_exemptions = 70141850;

Returns
Type Description
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
Type Description
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
Type Description
ByteString

The bytes for logType.

hasIgnoreChildExemptions()

public boolean hasIgnoreChildExemptions()

optional bool ignore_child_exemptions = 70141850;

Returns
Type Description
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
Type Description
boolean

Whether the logType field is set.

internalGetFieldAccessorTable()

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

isInitialized()

public final boolean isInitialized()
Returns
Type Description
boolean
Overrides

mergeFrom(AuditLogConfig other)

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

mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)

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

mergeFrom(Message other)

public AuditLogConfig.Builder mergeFrom(Message other)
Parameter
Name Description
other Message
Returns
Type Description
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
Name Description
index int

The index to set the value at.

value String

The exemptedMembers to set.

Returns
Type Description
AuditLogConfig.Builder

This builder for chaining.

setIgnoreChildExemptions(boolean value)

public AuditLogConfig.Builder setIgnoreChildExemptions(boolean value)

optional bool ignore_child_exemptions = 70141850;

Parameter
Name Description
value boolean

The ignoreChildExemptions to set.

Returns
Type Description
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
Name Description
value String

The logType to set.

Returns
Type Description
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
Name Description
value ByteString

The bytes for logType to set.

Returns
Type Description
AuditLogConfig.Builder

This builder for chaining.