Class FrequencyCap (0.7.0)

public final class FrequencyCap extends GeneratedMessageV3 implements FrequencyCapOrBuilder

Represents a Frequency Cap that can be applied to an entity.

Protobuf type google.ads.admanager.v1.FrequencyCap

Static Fields

MAX_IMPRESSIONS_FIELD_NUMBER

public static final int MAX_IMPRESSIONS_FIELD_NUMBER
Field Value
Type Description
int

TIME_AMOUNT_FIELD_NUMBER

public static final int TIME_AMOUNT_FIELD_NUMBER
Field Value
Type Description
int

TIME_UNIT_FIELD_NUMBER

public static final int TIME_UNIT_FIELD_NUMBER
Field Value
Type Description
int

Static Methods

getDefaultInstance()

public static FrequencyCap getDefaultInstance()
Returns
Type Description
FrequencyCap

getDescriptor()

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

newBuilder()

public static FrequencyCap.Builder newBuilder()
Returns
Type Description
FrequencyCap.Builder

newBuilder(FrequencyCap prototype)

public static FrequencyCap.Builder newBuilder(FrequencyCap prototype)
Parameter
Name Description
prototype FrequencyCap
Returns
Type Description
FrequencyCap.Builder

parseDelimitedFrom(InputStream input)

public static FrequencyCap parseDelimitedFrom(InputStream input)
Parameter
Name Description
input InputStream
Returns
Type Description
FrequencyCap
Exceptions
Type Description
IOException

parseDelimitedFrom(InputStream input, ExtensionRegistryLite extensionRegistry)

public static FrequencyCap parseDelimitedFrom(InputStream input, ExtensionRegistryLite extensionRegistry)
Parameters
Name Description
input InputStream
extensionRegistry ExtensionRegistryLite
Returns
Type Description
FrequencyCap
Exceptions
Type Description
IOException

parseFrom(byte[] data)

public static FrequencyCap parseFrom(byte[] data)
Parameter
Name Description
data byte[]
Returns
Type Description
FrequencyCap
Exceptions
Type Description
InvalidProtocolBufferException

parseFrom(byte[] data, ExtensionRegistryLite extensionRegistry)

public static FrequencyCap parseFrom(byte[] data, ExtensionRegistryLite extensionRegistry)
Parameters
Name Description
data byte[]
extensionRegistry ExtensionRegistryLite
Returns
Type Description
FrequencyCap
Exceptions
Type Description
InvalidProtocolBufferException

parseFrom(ByteString data)

public static FrequencyCap parseFrom(ByteString data)
Parameter
Name Description
data ByteString
Returns
Type Description
FrequencyCap
Exceptions
Type Description
InvalidProtocolBufferException

parseFrom(ByteString data, ExtensionRegistryLite extensionRegistry)

public static FrequencyCap parseFrom(ByteString data, ExtensionRegistryLite extensionRegistry)
Parameters
Name Description
data ByteString
extensionRegistry ExtensionRegistryLite
Returns
Type Description
FrequencyCap
Exceptions
Type Description
InvalidProtocolBufferException

parseFrom(CodedInputStream input)

public static FrequencyCap parseFrom(CodedInputStream input)
Parameter
Name Description
input CodedInputStream
Returns
Type Description
FrequencyCap
Exceptions
Type Description
IOException

parseFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)

public static FrequencyCap parseFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)
Parameters
Name Description
input CodedInputStream
extensionRegistry ExtensionRegistryLite
Returns
Type Description
FrequencyCap
Exceptions
Type Description
IOException

parseFrom(InputStream input)

public static FrequencyCap parseFrom(InputStream input)
Parameter
Name Description
input InputStream
Returns
Type Description
FrequencyCap
Exceptions
Type Description
IOException

parseFrom(InputStream input, ExtensionRegistryLite extensionRegistry)

public static FrequencyCap parseFrom(InputStream input, ExtensionRegistryLite extensionRegistry)
Parameters
Name Description
input InputStream
extensionRegistry ExtensionRegistryLite
Returns
Type Description
FrequencyCap
Exceptions
Type Description
IOException

parseFrom(ByteBuffer data)

public static FrequencyCap parseFrom(ByteBuffer data)
Parameter
Name Description
data ByteBuffer
Returns
Type Description
FrequencyCap
Exceptions
Type Description
InvalidProtocolBufferException

parseFrom(ByteBuffer data, ExtensionRegistryLite extensionRegistry)

public static FrequencyCap parseFrom(ByteBuffer data, ExtensionRegistryLite extensionRegistry)
Parameters
Name Description
data ByteBuffer
extensionRegistry ExtensionRegistryLite
Returns
Type Description
FrequencyCap
Exceptions
Type Description
InvalidProtocolBufferException

parser()

public static Parser<FrequencyCap> parser()
Returns
Type Description
Parser<FrequencyCap>

Methods

equals(Object obj)

public boolean equals(Object obj)
Parameter
Name Description
obj Object
Returns
Type Description
boolean
Overrides

getDefaultInstanceForType()

public FrequencyCap getDefaultInstanceForType()
Returns
Type Description
FrequencyCap

getMaxImpressions()

public long getMaxImpressions()

The maximum number of impressions for this frequency cap.

optional int64 max_impressions = 1;

Returns
Type Description
long

The maxImpressions.

getParserForType()

public Parser<FrequencyCap> getParserForType()
Returns
Type Description
Parser<FrequencyCap>
Overrides

getSerializedSize()

public int getSerializedSize()
Returns
Type Description
int
Overrides

getTimeAmount()

public long getTimeAmount()

The number of time units over which the frequency cap is effective.

optional int64 time_amount = 2;

Returns
Type Description
long

The timeAmount.

getTimeUnit()

public TimeUnitEnum.TimeUnit getTimeUnit()

The units of time of this frequency cap.

optional .google.ads.admanager.v1.TimeUnitEnum.TimeUnit time_unit = 3;

Returns
Type Description
TimeUnitEnum.TimeUnit

The timeUnit.

getTimeUnitValue()

public int getTimeUnitValue()

The units of time of this frequency cap.

optional .google.ads.admanager.v1.TimeUnitEnum.TimeUnit time_unit = 3;

Returns
Type Description
int

The enum numeric value on the wire for timeUnit.

hasMaxImpressions()

public boolean hasMaxImpressions()

The maximum number of impressions for this frequency cap.

optional int64 max_impressions = 1;

Returns
Type Description
boolean

Whether the maxImpressions field is set.

hasTimeAmount()

public boolean hasTimeAmount()

The number of time units over which the frequency cap is effective.

optional int64 time_amount = 2;

Returns
Type Description
boolean

Whether the timeAmount field is set.

hasTimeUnit()

public boolean hasTimeUnit()

The units of time of this frequency cap.

optional .google.ads.admanager.v1.TimeUnitEnum.TimeUnit time_unit = 3;

Returns
Type Description
boolean

Whether the timeUnit field is set.

hashCode()

public int hashCode()
Returns
Type Description
int
Overrides

internalGetFieldAccessorTable()

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

isInitialized()

public final boolean isInitialized()
Returns
Type Description
boolean
Overrides

newBuilderForType()

public FrequencyCap.Builder newBuilderForType()
Returns
Type Description
FrequencyCap.Builder

newBuilderForType(GeneratedMessageV3.BuilderParent parent)

protected FrequencyCap.Builder newBuilderForType(GeneratedMessageV3.BuilderParent parent)
Parameter
Name Description
parent BuilderParent
Returns
Type Description
FrequencyCap.Builder
Overrides

newInstance(GeneratedMessageV3.UnusedPrivateParameter unused)

protected Object newInstance(GeneratedMessageV3.UnusedPrivateParameter unused)
Parameter
Name Description
unused UnusedPrivateParameter
Returns
Type Description
Object
Overrides

toBuilder()

public FrequencyCap.Builder toBuilder()
Returns
Type Description
FrequencyCap.Builder

writeTo(CodedOutputStream output)

public void writeTo(CodedOutputStream output)
Parameter
Name Description
output CodedOutputStream
Overrides
Exceptions
Type Description
IOException