AdsApp.​FrequencyCapBuilder

Builder for FrequencyCap objects.

Methods:

MemberTypeDescription
buildvoidBuilds the frequency cap.
withEventTypeAdsApp.FrequencyCapBuilderSet the event type to the new frequency cap.
withLimitAdsApp.FrequencyCapBuilderSet the cap number to the new frequency cap.
withTimeUnitAdsApp.FrequencyCapBuilderSet the time unit to the new frequency cap.

build()

Builds the frequency cap.

Returns nothing.

withEventType(eventType)

Set the event type to the new frequency cap.

Arguments:

NameTypeDescription
eventTypeStringThe type of event that the cap applies to. The value can be either IMPRESSION or VIDEO_VIEW.

Return values:

TypeDescription
AdsApp.FrequencyCapBuilderThe frequency cap builder with the specified event type.

withLimit(limit)

Set the cap number to the new frequency cap.

Arguments:

NameTypeDescription
limitlongNumber of time units the cap lasts.

Return values:

TypeDescription
AdsApp.FrequencyCapBuilderThe frequency cap builder with the specified cap number.

withTimeUnit(timeUnit)

Set the time unit to the new frequency cap.

Arguments:

NameTypeDescription
timeUnitStringUnit of time the cap is defined at. The value can be DAY, WEEK or MONTH.

Return values:

TypeDescription
AdsApp.FrequencyCapBuilderThe frequency cap builder with the specified time unit.