Class RoleInfo.Builder (0.3.0)

public static final class RoleInfo.Builder extends GeneratedMessage.Builder<RoleInfo.Builder> implements RoleInfoOrBuilder

RoleInfo represents an IAM role along with its origin.

Protobuf type google.cloud.designcenter.v1.RoleInfo

Implements

RoleInfoOrBuilder

Static Methods

getDescriptor()

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

Methods

addAllPermissions(Iterable<String> values)

public RoleInfo.Builder addAllPermissions(Iterable<String> values)

Output only. The list of permissions that this role is recommended for. This includes only the permissions of this role that are part of the recommendation.

repeated string permissions = 3 [(.google.api.field_behavior) = OUTPUT_ONLY];

Parameter
Name Description
values Iterable<String>

The permissions to add.

Returns
Type Description
RoleInfo.Builder

This builder for chaining.

addPermissions(String value)

public RoleInfo.Builder addPermissions(String value)

Output only. The list of permissions that this role is recommended for. This includes only the permissions of this role that are part of the recommendation.

repeated string permissions = 3 [(.google.api.field_behavior) = OUTPUT_ONLY];

Parameter
Name Description
value String

The permissions to add.

Returns
Type Description
RoleInfo.Builder

This builder for chaining.

addPermissionsBytes(ByteString value)

public RoleInfo.Builder addPermissionsBytes(ByteString value)

Output only. The list of permissions that this role is recommended for. This includes only the permissions of this role that are part of the recommendation.

repeated string permissions = 3 [(.google.api.field_behavior) = OUTPUT_ONLY];

Parameter
Name Description
value ByteString

The bytes of the permissions to add.

Returns
Type Description
RoleInfo.Builder

This builder for chaining.

build()

public RoleInfo build()
Returns
Type Description
RoleInfo

buildPartial()

public RoleInfo buildPartial()
Returns
Type Description
RoleInfo

clear()

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

clearPermissions()

public RoleInfo.Builder clearPermissions()

Output only. The list of permissions that this role is recommended for. This includes only the permissions of this role that are part of the recommendation.

repeated string permissions = 3 [(.google.api.field_behavior) = OUTPUT_ONLY];

Returns
Type Description
RoleInfo.Builder

This builder for chaining.

clearRole()

public RoleInfo.Builder clearRole()

Required. IAM role name, such as roles/editor.

string role = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... }

Returns
Type Description
RoleInfo.Builder

This builder for chaining.

clearSystemProvided()

public RoleInfo.Builder clearSystemProvided()

Output only. When true, indicates that this role is automatically added by Application Design Center. When you provide a role, this field is set to false.

bool system_provided = 2 [(.google.api.field_behavior) = OUTPUT_ONLY];

Returns
Type Description
RoleInfo.Builder

This builder for chaining.

getDefaultInstanceForType()

public RoleInfo getDefaultInstanceForType()
Returns
Type Description
RoleInfo

getDescriptorForType()

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

getPermissions(int index)

public String getPermissions(int index)

Output only. The list of permissions that this role is recommended for. This includes only the permissions of this role that are part of the recommendation.

repeated string permissions = 3 [(.google.api.field_behavior) = OUTPUT_ONLY];

Parameter
Name Description
index int

The index of the element to return.

Returns
Type Description
String

The permissions at the given index.

getPermissionsBytes(int index)

public ByteString getPermissionsBytes(int index)

Output only. The list of permissions that this role is recommended for. This includes only the permissions of this role that are part of the recommendation.

repeated string permissions = 3 [(.google.api.field_behavior) = OUTPUT_ONLY];

Parameter
Name Description
index int

The index of the value to return.

Returns
Type Description
ByteString

The bytes of the permissions at the given index.

getPermissionsCount()

public int getPermissionsCount()

Output only. The list of permissions that this role is recommended for. This includes only the permissions of this role that are part of the recommendation.

repeated string permissions = 3 [(.google.api.field_behavior) = OUTPUT_ONLY];

Returns
Type Description
int

The count of permissions.

getPermissionsList()

public ProtocolStringList getPermissionsList()

Output only. The list of permissions that this role is recommended for. This includes only the permissions of this role that are part of the recommendation.

repeated string permissions = 3 [(.google.api.field_behavior) = OUTPUT_ONLY];

Returns
Type Description
ProtocolStringList

A list containing the permissions.

getRole()

public String getRole()

Required. IAM role name, such as roles/editor.

string role = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... }

Returns
Type Description
String

The role.

getRoleBytes()

public ByteString getRoleBytes()

Required. IAM role name, such as roles/editor.

string role = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... }

Returns
Type Description
ByteString

The bytes for role.

getSystemProvided()

public boolean getSystemProvided()

Output only. When true, indicates that this role is automatically added by Application Design Center. When you provide a role, this field is set to false.

bool system_provided = 2 [(.google.api.field_behavior) = OUTPUT_ONLY];

Returns
Type Description
boolean

The systemProvided.

internalGetFieldAccessorTable()

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

isInitialized()

public final boolean isInitialized()
Returns
Type Description
boolean
Overrides

mergeFrom(RoleInfo other)

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

mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)

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

mergeFrom(Message other)

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

setPermissions(int index, String value)

public RoleInfo.Builder setPermissions(int index, String value)

Output only. The list of permissions that this role is recommended for. This includes only the permissions of this role that are part of the recommendation.

repeated string permissions = 3 [(.google.api.field_behavior) = OUTPUT_ONLY];

Parameters
Name Description
index int

The index to set the value at.

value String

The permissions to set.

Returns
Type Description
RoleInfo.Builder

This builder for chaining.

setRole(String value)

public RoleInfo.Builder setRole(String value)

Required. IAM role name, such as roles/editor.

string role = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... }

Parameter
Name Description
value String

The role to set.

Returns
Type Description
RoleInfo.Builder

This builder for chaining.

setRoleBytes(ByteString value)

public RoleInfo.Builder setRoleBytes(ByteString value)

Required. IAM role name, such as roles/editor.

string role = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... }

Parameter
Name Description
value ByteString

The bytes for role to set.

Returns
Type Description
RoleInfo.Builder

This builder for chaining.

setSystemProvided(boolean value)

public RoleInfo.Builder setSystemProvided(boolean value)

Output only. When true, indicates that this role is automatically added by Application Design Center. When you provide a role, this field is set to false.

bool system_provided = 2 [(.google.api.field_behavior) = OUTPUT_ONLY];

Parameter
Name Description
value boolean

The systemProvided to set.

Returns
Type Description
RoleInfo.Builder

This builder for chaining.