Class DeviceCapabilityTargeting.Builder (0.39.0)

public static final class DeviceCapabilityTargeting.Builder extends GeneratedMessageV3.Builder<DeviceCapabilityTargeting.Builder> implements DeviceCapabilityTargetingOrBuilder

Device Capability Targeting.

Can be used to target/exclude users using mobile apps, ad requests resulting from apps built on the MRAID standard, or users on devices that are able to make phone calls versus devices that aren't able to make phone calls, such as tablets.

Protobuf type google.ads.admanager.v1.DeviceCapabilityTargeting

Static Methods

getDescriptor()

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

Methods

addAllExcludedCapabilities(Iterable<String> values)

public DeviceCapabilityTargeting.Builder addAllExcludedCapabilities(Iterable<String> values)

Optional. A list of device capability resource names that should be excluded.

repeated string excluded_capabilities = 4 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... }

Parameter
Name Description
values Iterable<String>

The excludedCapabilities to add.

Returns
Type Description
DeviceCapabilityTargeting.Builder

This builder for chaining.

addAllTargetedCapabilities(Iterable<String> values)

public DeviceCapabilityTargeting.Builder addAllTargetedCapabilities(Iterable<String> values)

Optional. A list of device capability resource names that should be targeted/included.

repeated string targeted_capabilities = 3 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... }

Parameter
Name Description
values Iterable<String>

The targetedCapabilities to add.

Returns
Type Description
DeviceCapabilityTargeting.Builder

This builder for chaining.

addExcludedCapabilities(String value)

public DeviceCapabilityTargeting.Builder addExcludedCapabilities(String value)

Optional. A list of device capability resource names that should be excluded.

repeated string excluded_capabilities = 4 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... }

Parameter
Name Description
value String

The excludedCapabilities to add.

Returns
Type Description
DeviceCapabilityTargeting.Builder

This builder for chaining.

addExcludedCapabilitiesBytes(ByteString value)

public DeviceCapabilityTargeting.Builder addExcludedCapabilitiesBytes(ByteString value)

Optional. A list of device capability resource names that should be excluded.

repeated string excluded_capabilities = 4 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... }

Parameter
Name Description
value ByteString

The bytes of the excludedCapabilities to add.

Returns
Type Description
DeviceCapabilityTargeting.Builder

This builder for chaining.

addRepeatedField(Descriptors.FieldDescriptor field, Object value)

public DeviceCapabilityTargeting.Builder addRepeatedField(Descriptors.FieldDescriptor field, Object value)
Parameters
Name Description
field FieldDescriptor
value Object
Returns
Type Description
DeviceCapabilityTargeting.Builder
Overrides

addTargetedCapabilities(String value)

public DeviceCapabilityTargeting.Builder addTargetedCapabilities(String value)

Optional. A list of device capability resource names that should be targeted/included.

repeated string targeted_capabilities = 3 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... }

Parameter
Name Description
value String

The targetedCapabilities to add.

Returns
Type Description
DeviceCapabilityTargeting.Builder

This builder for chaining.

addTargetedCapabilitiesBytes(ByteString value)

public DeviceCapabilityTargeting.Builder addTargetedCapabilitiesBytes(ByteString value)

Optional. A list of device capability resource names that should be targeted/included.

repeated string targeted_capabilities = 3 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... }

Parameter
Name Description
value ByteString

The bytes of the targetedCapabilities to add.

Returns
Type Description
DeviceCapabilityTargeting.Builder

This builder for chaining.

build()

public DeviceCapabilityTargeting build()
Returns
Type Description
DeviceCapabilityTargeting

buildPartial()

public DeviceCapabilityTargeting buildPartial()
Returns
Type Description
DeviceCapabilityTargeting

clear()

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

clearExcludedCapabilities()

public DeviceCapabilityTargeting.Builder clearExcludedCapabilities()

Optional. A list of device capability resource names that should be excluded.

repeated string excluded_capabilities = 4 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... }

Returns
Type Description
DeviceCapabilityTargeting.Builder

This builder for chaining.

clearField(Descriptors.FieldDescriptor field)

public DeviceCapabilityTargeting.Builder clearField(Descriptors.FieldDescriptor field)
Parameter
Name Description
field FieldDescriptor
Returns
Type Description
DeviceCapabilityTargeting.Builder
Overrides

clearOneof(Descriptors.OneofDescriptor oneof)

public DeviceCapabilityTargeting.Builder clearOneof(Descriptors.OneofDescriptor oneof)
Parameter
Name Description
oneof OneofDescriptor
Returns
Type Description
DeviceCapabilityTargeting.Builder
Overrides

clearTargetedCapabilities()

public DeviceCapabilityTargeting.Builder clearTargetedCapabilities()

Optional. A list of device capability resource names that should be targeted/included.

repeated string targeted_capabilities = 3 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... }

Returns
Type Description
DeviceCapabilityTargeting.Builder

This builder for chaining.

clone()

public DeviceCapabilityTargeting.Builder clone()
Returns
Type Description
DeviceCapabilityTargeting.Builder
Overrides

getDefaultInstanceForType()

public DeviceCapabilityTargeting getDefaultInstanceForType()
Returns
Type Description
DeviceCapabilityTargeting

getDescriptorForType()

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

getExcludedCapabilities(int index)

public String getExcludedCapabilities(int index)

Optional. A list of device capability resource names that should be excluded.

repeated string excluded_capabilities = 4 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... }

Parameter
Name Description
index int

The index of the element to return.

Returns
Type Description
String

The excludedCapabilities at the given index.

getExcludedCapabilitiesBytes(int index)

public ByteString getExcludedCapabilitiesBytes(int index)

Optional. A list of device capability resource names that should be excluded.

repeated string excluded_capabilities = 4 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... }

Parameter
Name Description
index int

The index of the value to return.

Returns
Type Description
ByteString

The bytes of the excludedCapabilities at the given index.

getExcludedCapabilitiesCount()

public int getExcludedCapabilitiesCount()

Optional. A list of device capability resource names that should be excluded.

repeated string excluded_capabilities = 4 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... }

Returns
Type Description
int

The count of excludedCapabilities.

getExcludedCapabilitiesList()

public ProtocolStringList getExcludedCapabilitiesList()

Optional. A list of device capability resource names that should be excluded.

repeated string excluded_capabilities = 4 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... }

Returns
Type Description
ProtocolStringList

A list containing the excludedCapabilities.

getTargetedCapabilities(int index)

public String getTargetedCapabilities(int index)

Optional. A list of device capability resource names that should be targeted/included.

repeated string targeted_capabilities = 3 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... }

Parameter
Name Description
index int

The index of the element to return.

Returns
Type Description
String

The targetedCapabilities at the given index.

getTargetedCapabilitiesBytes(int index)

public ByteString getTargetedCapabilitiesBytes(int index)

Optional. A list of device capability resource names that should be targeted/included.

repeated string targeted_capabilities = 3 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... }

Parameter
Name Description
index int

The index of the value to return.

Returns
Type Description
ByteString

The bytes of the targetedCapabilities at the given index.

getTargetedCapabilitiesCount()

public int getTargetedCapabilitiesCount()

Optional. A list of device capability resource names that should be targeted/included.

repeated string targeted_capabilities = 3 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... }

Returns
Type Description
int

The count of targetedCapabilities.

getTargetedCapabilitiesList()

public ProtocolStringList getTargetedCapabilitiesList()

Optional. A list of device capability resource names that should be targeted/included.

repeated string targeted_capabilities = 3 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... }

Returns
Type Description
ProtocolStringList

A list containing the targetedCapabilities.

internalGetFieldAccessorTable()

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

isInitialized()

public final boolean isInitialized()
Returns
Type Description
boolean
Overrides

mergeFrom(DeviceCapabilityTargeting other)

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

mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)

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

mergeFrom(Message other)

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

mergeUnknownFields(UnknownFieldSet unknownFields)

public final DeviceCapabilityTargeting.Builder mergeUnknownFields(UnknownFieldSet unknownFields)
Parameter
Name Description
unknownFields UnknownFieldSet
Returns
Type Description
DeviceCapabilityTargeting.Builder
Overrides

setExcludedCapabilities(int index, String value)

public DeviceCapabilityTargeting.Builder setExcludedCapabilities(int index, String value)

Optional. A list of device capability resource names that should be excluded.

repeated string excluded_capabilities = 4 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... }

Parameters
Name Description
index int

The index to set the value at.

value String

The excludedCapabilities to set.

Returns
Type Description
DeviceCapabilityTargeting.Builder

This builder for chaining.

setField(Descriptors.FieldDescriptor field, Object value)

public DeviceCapabilityTargeting.Builder setField(Descriptors.FieldDescriptor field, Object value)
Parameters
Name Description
field FieldDescriptor
value Object
Returns
Type Description
DeviceCapabilityTargeting.Builder
Overrides

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

public DeviceCapabilityTargeting.Builder setRepeatedField(Descriptors.FieldDescriptor field, int index, Object value)
Parameters
Name Description
field FieldDescriptor
index int
value Object
Returns
Type Description
DeviceCapabilityTargeting.Builder
Overrides

setTargetedCapabilities(int index, String value)

public DeviceCapabilityTargeting.Builder setTargetedCapabilities(int index, String value)

Optional. A list of device capability resource names that should be targeted/included.

repeated string targeted_capabilities = 3 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... }

Parameters
Name Description
index int

The index to set the value at.

value String

The targetedCapabilities to set.

Returns
Type Description
DeviceCapabilityTargeting.Builder

This builder for chaining.

setUnknownFields(UnknownFieldSet unknownFields)

public final DeviceCapabilityTargeting.Builder setUnknownFields(UnknownFieldSet unknownFields)
Parameter
Name Description
unknownFields UnknownFieldSet
Returns
Type Description
DeviceCapabilityTargeting.Builder
Overrides