Class DeviceCategory.Builder (0.44.0)

public static final class DeviceCategory.Builder extends GeneratedMessage.Builder<DeviceCategory.Builder> implements DeviceCategoryOrBuilder

Represents the category of a device. For example, "smartphone" or "desktop".

Protobuf type google.ads.admanager.v1.DeviceCategory

Static Methods

getDescriptor()

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

Methods

build()

public DeviceCategory build()
Returns
Type Description
DeviceCategory

buildPartial()

public DeviceCategory buildPartial()
Returns
Type Description
DeviceCategory

clear()

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

clearDisplayName()

public DeviceCategory.Builder clearDisplayName()

Output only. The display name of the device category.

optional string display_name = 2 [(.google.api.field_behavior) = OUTPUT_ONLY];

Returns
Type Description
DeviceCategory.Builder

This builder for chaining.

clearName()

public DeviceCategory.Builder clearName()

Identifier. The resource name of the DeviceCategory. Format: networks/{network_code}/deviceCategories/{device_category}

string name = 1 [(.google.api.field_behavior) = IDENTIFIER];

Returns
Type Description
DeviceCategory.Builder

This builder for chaining.

getDefaultInstanceForType()

public DeviceCategory getDefaultInstanceForType()
Returns
Type Description
DeviceCategory

getDescriptorForType()

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

getDisplayName()

public String getDisplayName()

Output only. The display name of the device category.

optional string display_name = 2 [(.google.api.field_behavior) = OUTPUT_ONLY];

Returns
Type Description
String

The displayName.

getDisplayNameBytes()

public ByteString getDisplayNameBytes()

Output only. The display name of the device category.

optional string display_name = 2 [(.google.api.field_behavior) = OUTPUT_ONLY];

Returns
Type Description
ByteString

The bytes for displayName.

getName()

public String getName()

Identifier. The resource name of the DeviceCategory. Format: networks/{network_code}/deviceCategories/{device_category}

string name = 1 [(.google.api.field_behavior) = IDENTIFIER];

Returns
Type Description
String

The name.

getNameBytes()

public ByteString getNameBytes()

Identifier. The resource name of the DeviceCategory. Format: networks/{network_code}/deviceCategories/{device_category}

string name = 1 [(.google.api.field_behavior) = IDENTIFIER];

Returns
Type Description
ByteString

The bytes for name.

hasDisplayName()

public boolean hasDisplayName()

Output only. The display name of the device category.

optional string display_name = 2 [(.google.api.field_behavior) = OUTPUT_ONLY];

Returns
Type Description
boolean

Whether the displayName field is set.

internalGetFieldAccessorTable()

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

isInitialized()

public final boolean isInitialized()
Returns
Type Description
boolean
Overrides

mergeFrom(DeviceCategory other)

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

mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)

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

mergeFrom(Message other)

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

setDisplayName(String value)

public DeviceCategory.Builder setDisplayName(String value)

Output only. The display name of the device category.

optional string display_name = 2 [(.google.api.field_behavior) = OUTPUT_ONLY];

Parameter
Name Description
value String

The displayName to set.

Returns
Type Description
DeviceCategory.Builder

This builder for chaining.

setDisplayNameBytes(ByteString value)

public DeviceCategory.Builder setDisplayNameBytes(ByteString value)

Output only. The display name of the device category.

optional string display_name = 2 [(.google.api.field_behavior) = OUTPUT_ONLY];

Parameter
Name Description
value ByteString

The bytes for displayName to set.

Returns
Type Description
DeviceCategory.Builder

This builder for chaining.

setName(String value)

public DeviceCategory.Builder setName(String value)

Identifier. The resource name of the DeviceCategory. Format: networks/{network_code}/deviceCategories/{device_category}

string name = 1 [(.google.api.field_behavior) = IDENTIFIER];

Parameter
Name Description
value String

The name to set.

Returns
Type Description
DeviceCategory.Builder

This builder for chaining.

setNameBytes(ByteString value)

public DeviceCategory.Builder setNameBytes(ByteString value)

Identifier. The resource name of the DeviceCategory. Format: networks/{network_code}/deviceCategories/{device_category}

string name = 1 [(.google.api.field_behavior) = IDENTIFIER];

Parameter
Name Description
value ByteString

The bytes for name to set.

Returns
Type Description
DeviceCategory.Builder

This builder for chaining.