Class AclRule.Builder (0.49.0)

public static final class AclRule.Builder extends GeneratedMessage.Builder<AclRule.Builder> implements AclRuleOrBuilder

A single ACL rule which defines the policy for a user.

Protobuf type google.cloud.memorystore.v1.AclRule

Implements

AclRuleOrBuilder

Static Methods

getDescriptor()

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

Methods

build()

public AclRule build()
Returns
Type Description
AclRule

buildPartial()

public AclRule buildPartial()
Returns
Type Description
AclRule

clear()

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

clearRule()

public AclRule.Builder clearRule()

Required. The rule to be applied to the username. Ex: "on >password123 ~* +@all" The format of the rule is defined by Valkey OSS: https://valkey.io/topics/acl/

string rule = 2 [(.google.api.field_behavior) = REQUIRED];

Returns
Type Description
AclRule.Builder

This builder for chaining.

clearUsername()

public AclRule.Builder clearUsername()

Required. Specifies the IAM user or service account to be added to the ACL policy. This username will be directly set on the Valkey OSS.

string username = 1 [(.google.api.field_behavior) = REQUIRED];

Returns
Type Description
AclRule.Builder

This builder for chaining.

getDefaultInstanceForType()

public AclRule getDefaultInstanceForType()
Returns
Type Description
AclRule

getDescriptorForType()

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

getRule()

public String getRule()

Required. The rule to be applied to the username. Ex: "on >password123 ~* +@all" The format of the rule is defined by Valkey OSS: https://valkey.io/topics/acl/

string rule = 2 [(.google.api.field_behavior) = REQUIRED];

Returns
Type Description
String

The rule.

getRuleBytes()

public ByteString getRuleBytes()

Required. The rule to be applied to the username. Ex: "on >password123 ~* +@all" The format of the rule is defined by Valkey OSS: https://valkey.io/topics/acl/

string rule = 2 [(.google.api.field_behavior) = REQUIRED];

Returns
Type Description
ByteString

The bytes for rule.

getUsername()

public String getUsername()

Required. Specifies the IAM user or service account to be added to the ACL policy. This username will be directly set on the Valkey OSS.

string username = 1 [(.google.api.field_behavior) = REQUIRED];

Returns
Type Description
String

The username.

getUsernameBytes()

public ByteString getUsernameBytes()

Required. Specifies the IAM user or service account to be added to the ACL policy. This username will be directly set on the Valkey OSS.

string username = 1 [(.google.api.field_behavior) = REQUIRED];

Returns
Type Description
ByteString

The bytes for username.

internalGetFieldAccessorTable()

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

isInitialized()

public final boolean isInitialized()
Returns
Type Description
boolean
Overrides

mergeFrom(AclRule other)

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

mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)

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

mergeFrom(Message other)

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

setRule(String value)

public AclRule.Builder setRule(String value)

Required. The rule to be applied to the username. Ex: "on >password123 ~* +@all" The format of the rule is defined by Valkey OSS: https://valkey.io/topics/acl/

string rule = 2 [(.google.api.field_behavior) = REQUIRED];

Parameter
Name Description
value String

The rule to set.

Returns
Type Description
AclRule.Builder

This builder for chaining.

setRuleBytes(ByteString value)

public AclRule.Builder setRuleBytes(ByteString value)

Required. The rule to be applied to the username. Ex: "on >password123 ~* +@all" The format of the rule is defined by Valkey OSS: https://valkey.io/topics/acl/

string rule = 2 [(.google.api.field_behavior) = REQUIRED];

Parameter
Name Description
value ByteString

The bytes for rule to set.

Returns
Type Description
AclRule.Builder

This builder for chaining.

setUsername(String value)

public AclRule.Builder setUsername(String value)

Required. Specifies the IAM user or service account to be added to the ACL policy. This username will be directly set on the Valkey OSS.

string username = 1 [(.google.api.field_behavior) = REQUIRED];

Parameter
Name Description
value String

The username to set.

Returns
Type Description
AclRule.Builder

This builder for chaining.

setUsernameBytes(ByteString value)

public AclRule.Builder setUsernameBytes(ByteString value)

Required. Specifies the IAM user or service account to be added to the ACL policy. This username will be directly set on the Valkey OSS.

string username = 1 [(.google.api.field_behavior) = REQUIRED];

Parameter
Name Description
value ByteString

The bytes for username to set.

Returns
Type Description
AclRule.Builder

This builder for chaining.