public class ProductTemplate extends Object implements Serializable
ProductTemplate is used to generate products. All generated
products will
inherit all attributes from their ProductTemplate,
except for segmentation,
which will be included in the Product#targeting.
The generated products in turn will be
used to create proposal line items
so that almost all attributes
in the product template are properties of the proposal
line item.| Constructor and Description |
|---|
ProductTemplate() |
ProductTemplate(Long id,
String name,
DateTime creationDateTime,
DateTime lastModifiedDateTime,
String description,
String nameMacro,
ProductTemplateStatus status,
ProductType productType,
Long creatorId,
RateType rateType,
RoadblockingType roadblockingType,
DeliveryRateType deliveryRateType,
CreativeRotationType creativeRotationType,
CompanionDeliveryOption companionDeliveryOption,
CreativePlaceholder[] creativePlaceholders,
LineItemType lineItemType,
Integer priority,
FrequencyCap[] frequencyCaps,
ProductSegmentation productSegmentation,
Targeting builtInTargeting,
CustomizableAttributes customizableAttributes,
BaseCustomFieldValue[] customFieldValues,
EnvironmentType environmentType,
Long videoMaxDuration,
ProductTemplateMarketplaceInfo productTemplateMarketplaceInfo) |
| Modifier and Type | Method and Description |
|---|---|
boolean |
equals(Object obj) |
Targeting |
getBuiltInTargeting()
Gets the builtInTargeting value for this ProductTemplate.
|
CompanionDeliveryOption |
getCompanionDeliveryOption()
Gets the companionDeliveryOption value for this ProductTemplate.
|
DateTime |
getCreationDateTime()
Gets the creationDateTime value for this ProductTemplate.
|
CreativePlaceholder[] |
getCreativePlaceholders()
Gets the creativePlaceholders value for this ProductTemplate.
|
CreativePlaceholder |
getCreativePlaceholders(int i) |
CreativeRotationType |
getCreativeRotationType()
Gets the creativeRotationType value for this ProductTemplate.
|
Long |
getCreatorId()
Gets the creatorId value for this ProductTemplate.
|
BaseCustomFieldValue[] |
getCustomFieldValues()
Gets the customFieldValues value for this ProductTemplate.
|
BaseCustomFieldValue |
getCustomFieldValues(int i) |
CustomizableAttributes |
getCustomizableAttributes()
Gets the customizableAttributes value for this ProductTemplate.
|
DeliveryRateType |
getDeliveryRateType()
Gets the deliveryRateType value for this ProductTemplate.
|
String |
getDescription()
Gets the description value for this ProductTemplate.
|
static org.apache.axis.encoding.Deserializer |
getDeserializer(String mechType,
Class _javaType,
QName _xmlType)
Get Custom Deserializer
|
EnvironmentType |
getEnvironmentType()
Gets the environmentType value for this ProductTemplate.
|
FrequencyCap[] |
getFrequencyCaps()
Gets the frequencyCaps value for this ProductTemplate.
|
FrequencyCap |
getFrequencyCaps(int i) |
Long |
getId()
Gets the id value for this ProductTemplate.
|
DateTime |
getLastModifiedDateTime()
Gets the lastModifiedDateTime value for this ProductTemplate.
|
LineItemType |
getLineItemType()
Gets the lineItemType value for this ProductTemplate.
|
String |
getName()
Gets the name value for this ProductTemplate.
|
String |
getNameMacro()
Gets the nameMacro value for this ProductTemplate.
|
Integer |
getPriority()
Gets the priority value for this ProductTemplate.
|
ProductSegmentation |
getProductSegmentation()
Gets the productSegmentation value for this ProductTemplate.
|
ProductTemplateMarketplaceInfo |
getProductTemplateMarketplaceInfo()
Gets the productTemplateMarketplaceInfo value for this ProductTemplate.
|
ProductType |
getProductType()
Gets the productType value for this ProductTemplate.
|
RateType |
getRateType()
Gets the rateType value for this ProductTemplate.
|
RoadblockingType |
getRoadblockingType()
Gets the roadblockingType value for this ProductTemplate.
|
static org.apache.axis.encoding.Serializer |
getSerializer(String mechType,
Class _javaType,
QName _xmlType)
Get Custom Serializer
|
ProductTemplateStatus |
getStatus()
Gets the status value for this ProductTemplate.
|
static org.apache.axis.description.TypeDesc |
getTypeDesc()
Return type metadata object
|
Long |
getVideoMaxDuration()
Gets the videoMaxDuration value for this ProductTemplate.
|
int |
hashCode() |
void |
setBuiltInTargeting(Targeting builtInTargeting)
Sets the builtInTargeting value for this ProductTemplate.
|
void |
setCompanionDeliveryOption(CompanionDeliveryOption companionDeliveryOption)
Sets the companionDeliveryOption value for this ProductTemplate.
|
void |
setCreationDateTime(DateTime creationDateTime)
Sets the creationDateTime value for this ProductTemplate.
|
void |
setCreativePlaceholders(CreativePlaceholder[] creativePlaceholders)
Sets the creativePlaceholders value for this ProductTemplate.
|
void |
setCreativePlaceholders(int i,
CreativePlaceholder _value) |
void |
setCreativeRotationType(CreativeRotationType creativeRotationType)
Sets the creativeRotationType value for this ProductTemplate.
|
void |
setCreatorId(Long creatorId)
Sets the creatorId value for this ProductTemplate.
|
void |
setCustomFieldValues(BaseCustomFieldValue[] customFieldValues)
Sets the customFieldValues value for this ProductTemplate.
|
void |
setCustomFieldValues(int i,
BaseCustomFieldValue _value) |
void |
setCustomizableAttributes(CustomizableAttributes customizableAttributes)
Sets the customizableAttributes value for this ProductTemplate.
|
void |
setDeliveryRateType(DeliveryRateType deliveryRateType)
Sets the deliveryRateType value for this ProductTemplate.
|
void |
setDescription(String description)
Sets the description value for this ProductTemplate.
|
void |
setEnvironmentType(EnvironmentType environmentType)
Sets the environmentType value for this ProductTemplate.
|
void |
setFrequencyCaps(FrequencyCap[] frequencyCaps)
Sets the frequencyCaps value for this ProductTemplate.
|
void |
setFrequencyCaps(int i,
FrequencyCap _value) |
void |
setId(Long id)
Sets the id value for this ProductTemplate.
|
void |
setLastModifiedDateTime(DateTime lastModifiedDateTime)
Sets the lastModifiedDateTime value for this ProductTemplate.
|
void |
setLineItemType(LineItemType lineItemType)
Sets the lineItemType value for this ProductTemplate.
|
void |
setName(String name)
Sets the name value for this ProductTemplate.
|
void |
setNameMacro(String nameMacro)
Sets the nameMacro value for this ProductTemplate.
|
void |
setPriority(Integer priority)
Sets the priority value for this ProductTemplate.
|
void |
setProductSegmentation(ProductSegmentation productSegmentation)
Sets the productSegmentation value for this ProductTemplate.
|
void |
setProductTemplateMarketplaceInfo(ProductTemplateMarketplaceInfo productTemplateMarketplaceInfo)
Sets the productTemplateMarketplaceInfo value for this ProductTemplate.
|
void |
setProductType(ProductType productType)
Sets the productType value for this ProductTemplate.
|
void |
setRateType(RateType rateType)
Sets the rateType value for this ProductTemplate.
|
void |
setRoadblockingType(RoadblockingType roadblockingType)
Sets the roadblockingType value for this ProductTemplate.
|
void |
setStatus(ProductTemplateStatus status)
Sets the status value for this ProductTemplate.
|
void |
setVideoMaxDuration(Long videoMaxDuration)
Sets the videoMaxDuration value for this ProductTemplate.
|
String |
toString() |
public ProductTemplate()
public ProductTemplate(Long id, String name, DateTime creationDateTime, DateTime lastModifiedDateTime, String description, String nameMacro, ProductTemplateStatus status, ProductType productType, Long creatorId, RateType rateType, RoadblockingType roadblockingType, DeliveryRateType deliveryRateType, CreativeRotationType creativeRotationType, CompanionDeliveryOption companionDeliveryOption, CreativePlaceholder[] creativePlaceholders, LineItemType lineItemType, Integer priority, FrequencyCap[] frequencyCaps, ProductSegmentation productSegmentation, Targeting builtInTargeting, CustomizableAttributes customizableAttributes, BaseCustomFieldValue[] customFieldValues, EnvironmentType environmentType, Long videoMaxDuration, ProductTemplateMarketplaceInfo productTemplateMarketplaceInfo)
public Long getId()
ProductTemplate.
This attribute is read-only and is assigned by Google
when a ProductTemplate
is created.public void setId(Long id)
id - * Uniquely identifies the ProductTemplate.
This attribute is read-only and is assigned by Google
when a ProductTemplate
is created.public String getName()
ProductTemplate.
This attribute has maximum length of 255 characters.
This attribute is required.public void setName(String name)
name - * The name of the ProductTemplate.
This attribute has maximum length of 255 characters.
This attribute is required.public DateTime getCreationDateTime()
ProductTemplate.
This attribute is read-only and is assigned by Google
when a ProductTemplate
is created.public void setCreationDateTime(DateTime creationDateTime)
creationDateTime - * The creation time of the ProductTemplate.
This attribute is read-only and is assigned by Google
when a ProductTemplate
is created.public DateTime getLastModifiedDateTime()
ProductTemplate was last modified.
This attribute is read-only and is assigned by Google
when a ProductTemplate
is updated.public void setLastModifiedDateTime(DateTime lastModifiedDateTime)
lastModifiedDateTime - * The date and time this ProductTemplate was last modified.
This attribute is read-only and is assigned by Google
when a ProductTemplate
is updated.public String getDescription()
ProductTemplate.
This attribute has maximum length of 511 characters.
This attribute is optional.public void setDescription(String description)
description - * The description of the ProductTemplate.
This attribute has maximum length of 511 characters.
This attribute is optional.public String getNameMacro()
ProductTemplate. The name macro
is used to generate the Product.name. This attribute is required and has
maximum length of 1023 characters.
The name macro can contain plain text and several
placeholders that will be replaced with
values specified in the ProductTemplate when
generating product names.
Allowed placeholders are:
| Placeholder | Segmentation |
|---|---|
<ad-unit> |
ProductSegmentation.adUnitSegments |
<placement> |
ProductSegmentation.placementSegment |
<location> |
ProductSegmentation.geoSegment |
<user-domain> |
ProductSegmentation.userDomainSegment |
<bandwidth-group> |
ProductSegmentation.bandwidthSegment |
<browser> |
ProductSegmentation.browserSegment |
<browser-language> |
ProductSegmentation.browserLanguageSegment |
<operating-system> |
ProductSegmentation.operatingSystemSegment |
<frequency-cap> |
frequencyCaps |
<rate-type> |
rateType |
<creative-placeholder-size> |
creativePlaceholders |
<line-item-type> |
lineItemType |
<line-item-priority> |
priority |
<template-name> |
name |
public void setNameMacro(String nameMacro)
nameMacro - * The name macro of the ProductTemplate. The name macro
is used to generate the Product.name. This attribute is required and has
maximum length of 1023 characters.
The name macro can contain plain text and several
placeholders that will be replaced with
values specified in the ProductTemplate when
generating product names.
Allowed placeholders are:
| Placeholder | Segmentation |
|---|---|
<ad-unit> |
ProductSegmentation.adUnitSegments |
<placement> |
ProductSegmentation.placementSegment |
<location> |
ProductSegmentation.geoSegment |
<user-domain> |
ProductSegmentation.userDomainSegment |
<bandwidth-group> |
ProductSegmentation.bandwidthSegment |
<browser> |
ProductSegmentation.browserSegment |
<browser-language> |
ProductSegmentation.browserLanguageSegment |
<operating-system> |
ProductSegmentation.operatingSystemSegment |
<frequency-cap> |
frequencyCaps |
<rate-type> |
rateType |
<creative-placeholder-size> |
creativePlaceholders |
<line-item-type> |
lineItemType |
<line-item-priority> |
priority |
<template-name> |
name |
public ProductTemplateStatus getStatus()
ProductTemplate.
This attribute is read-only.public void setStatus(ProductTemplateStatus status)
status - * The status of the ProductTemplate.
This attribute is read-only.public ProductType getProductType()
Product.
Note: if the type is ProductType.OFFLINE,
then the following fields must be
null or empty:
roadblockingType, lineItemType,
frequencyCaps,
productSegmentation and #targeting.
This attribute is required.public void setProductType(ProductType productType)
productType - * The type of generated Product.
Note: if the type is ProductType.OFFLINE,
then the following fields must be
null or empty:
roadblockingType, lineItemType,
frequencyCaps,
productSegmentation and #targeting.
This attribute is required.public Long getCreatorId()
id of the user who created the ProductTemplate.
This attribute is read-only and is assigned by Google.public void setCreatorId(Long creatorId)
creatorId - * The id of the user who created the ProductTemplate.
This attribute is read-only and is assigned by Google.public RateType getRateType()
ProposalLineItem.
This attribute is required.public void setRateType(RateType rateType)
rateType - * The method used for billing the created ProposalLineItem.
This attribute is required.public RoadblockingType getRoadblockingType()
RoadblockingType.ONE_OR_MORE
if
productType is ProductType.DFP, or
RoadblockingType.CREATIVE_SET
if there are companion sizes in creativePlaceholders.public void setRoadblockingType(RoadblockingType roadblockingType)
roadblockingType - * The strategy for serving roadblocked creatives, i.e. instances
where
multiple creatives must be served together on a single
web page. This
attribute is optional and defaults to RoadblockingType.ONE_OR_MORE
if
productType is ProductType.DFP, or
RoadblockingType.CREATIVE_SET
if there are companion sizes in creativePlaceholders.public DeliveryRateType getDeliveryRateType()
DeliveryRateType.EVENLY if
productType is ProductType.DFP.public void setDeliveryRateType(DeliveryRateType deliveryRateType)
deliveryRateType - * The strategy for delivering ads over the course of the line
item's duration.
This attribute is optional and defaults to DeliveryRateType.EVENLY if
productType is ProductType.DFP.public CreativeRotationType getCreativeRotationType()
Creative
objects that are
associated with the created ProposalLineItem.
This attribute is optional and
defaults to CreativeRotationType.OPTIMIZED
if productType
is ProductType.DFP.public void setCreativeRotationType(CreativeRotationType creativeRotationType)
creativeRotationType - * The strategy used for displaying multiple Creative
objects that are
associated with the created ProposalLineItem.
This attribute is optional and
defaults to CreativeRotationType.OPTIMIZED
if productType
is ProductType.DFP.public CompanionDeliveryOption getCompanionDeliveryOption()
This field is optional and defaults to
CompanionDeliveryOption.OPTIONAL if the above
conditions are met and
productType is ProductType.DFP.
public void setCompanionDeliveryOption(CompanionDeliveryOption companionDeliveryOption)
companionDeliveryOption - * The delivery option for companions. Setting this field is only
meaningful
if the following conditions are met:
This field is optional and defaults to
CompanionDeliveryOption.OPTIONAL if the above
conditions are met and
productType is ProductType.DFP.
public CreativePlaceholder[] getCreativePlaceholders()
ProposalLineItem.
For a roadblockingType of RoadblockingType.CREATIVE_SET,
all
creative placeholders must have a master and at least
one companion size.
This attribute is required when productType
is ProductType.DFP.
public void setCreativePlaceholders(CreativePlaceholder[] creativePlaceholders)
creativePlaceholders - * Details about the creatives that are expected to serve for
the created ProposalLineItem.
For a roadblockingType of RoadblockingType.CREATIVE_SET,
all
creative placeholders must have a master and at least
one companion size.
This attribute is required when productType
is ProductType.DFP.
public CreativePlaceholder getCreativePlaceholders(int i)
public void setCreativePlaceholders(int i,
CreativePlaceholder _value)
public LineItemType getLineItemType()
ProposalLineItem.
This attribute is required when productType
is ProductType.DFP.public void setLineItemType(LineItemType lineItemType)
lineItemType - * Indicates the line item type for the created ProposalLineItem.
This attribute is required when productType
is ProductType.DFP.public Integer getPriority()
ProposalLineItem. The priority is a value
between 1 and 16. If not specified, the default priority of the
LineItemType will be assigned. The following
default, minimum and
maximum priority values is allowed for each line item
type:
| LineItemType | Default Priority | Minimum Priority | Maximum priority |
|---|---|---|---|
LineItemType.SPONSORSHIP |
4 | 2 | 5 |
LineItemType.STANDARD |
8 | 6 | 10 |
LineItemType.NETWORK |
12 | 11 | 14 |
LineItemType.BULK |
12 | 11 | 14 |
LineItemType.PRICE_PRIORITY |
12 | 11 | 14 |
LineItemType.HOUSE |
16 | 15 | 16 |
productType is ProductType.OFFLINE.public void setPriority(Integer priority)
priority - * Priority of ProposalLineItem. The priority is a value
between 1 and 16. If not specified, the default priority of the
LineItemType will be assigned. The following
default, minimum and
maximum priority values is allowed for each line item
type:
| LineItemType | Default Priority | Minimum Priority | Maximum priority |
|---|---|---|---|
LineItemType.SPONSORSHIP |
4 | 2 | 5 |
LineItemType.STANDARD |
8 | 6 | 10 |
LineItemType.NETWORK |
12 | 11 | 14 |
LineItemType.BULK |
12 | 11 | 14 |
LineItemType.PRICE_PRIORITY |
12 | 11 | 14 |
LineItemType.HOUSE |
16 | 15 | 16 |
productType is ProductType.OFFLINE.public FrequencyCap[] getFrequencyCaps()
ProposalLineItem.
Each frequency cap in the list must have unique TimeUnit.
This attribute is optional.public void setFrequencyCaps(FrequencyCap[] frequencyCaps)
frequencyCaps - * The set of frequency capping units for the created ProposalLineItem.
Each frequency cap in the list must have unique TimeUnit.
This attribute is optional.public FrequencyCap getFrequencyCaps(int i)
public void setFrequencyCaps(int i,
FrequencyCap _value)
public ProductSegmentation getProductSegmentation()
#targeting will
produce the targeting on the resulting ProposalLineItem.
Any type of segmentation cannot also be used for targeting.
This attribute is optional.
Note: if you specify ProducSegmentation#geoSegment,
then
ProductTemplateTargeting#geoTargeting must
be null or empty, vice versa. This also
applies to other targeting and segmentation.public void setProductSegmentation(ProductSegmentation productSegmentation)
productSegmentation - * The product segmentation. The combination from the segments
and the #targeting will
produce the targeting on the resulting ProposalLineItem.
Any type of segmentation cannot also be used for targeting.
This attribute is optional.
Note: if you specify ProducSegmentation#geoSegment,
then
ProductTemplateTargeting#geoTargeting must
be null or empty, vice versa. This also
applies to other targeting and segmentation.public Targeting getBuiltInTargeting()
ProposalLineItem.
Any type targeted cannot also be used for segmentation.
This attribute is optional.
Note: if productType is ProductType.DFP
and productSegmentation is
not specified, this attribute is required.
public void setBuiltInTargeting(Targeting builtInTargeting)
builtInTargeting - * Targeting to be included in the created ProposalLineItem.
Any type targeted cannot also be used for segmentation.
This attribute is optional.
Note: if productType is ProductType.DFP
and productSegmentation is
not specified, this attribute is required.
public CustomizableAttributes getCustomizableAttributes()
ProposalLineItem
are customizable.
This attribute is optional. If not specified, then no targeting or attributes are customizable.
public void setCustomizableAttributes(CustomizableAttributes customizableAttributes)
customizableAttributes - * Specifies what targeting or attributes for the created ProposalLineItem
are customizable.
This attribute is optional. If not specified, then no targeting or attributes are customizable.
public BaseCustomFieldValue[] getCustomFieldValues()
ProductTemplate.
This attribute is optional.public void setCustomFieldValues(BaseCustomFieldValue[] customFieldValues)
customFieldValues - * The values of the custom fields associated with this ProductTemplate.
This attribute is optional.public BaseCustomFieldValue getCustomFieldValues(int i)
public void setCustomFieldValues(int i,
BaseCustomFieldValue _value)
public EnvironmentType getEnvironmentType()
ProposalLineItem is
targeting. The default value is
EnvironmentType.BROWSER. If this value is
EnvironmentType.VIDEO_PLAYER, then
the ProposalLineItem can only target AdUnits that have AdUnitSizes
whose environmentType is also VIDEO_PLAYER.public void setEnvironmentType(EnvironmentType environmentType)
environmentType - * The environment that the created ProposalLineItem is
targeting. The default value is
EnvironmentType.BROWSER. If this value is
EnvironmentType.VIDEO_PLAYER, then
the ProposalLineItem can only target AdUnits that have AdUnitSizes
whose environmentType is also VIDEO_PLAYER.public Long getVideoMaxDuration()
ProductTemplate in
milliseconds. This attribute is optional, defaults
to 0, and only meaningful if this is
a video product template.public void setVideoMaxDuration(Long videoMaxDuration)
videoMaxDuration - * The max duration of a video creative associated with this ProductTemplate in
milliseconds. This attribute is optional, defaults
to 0, and only meaningful if this is
a video product template.public ProductTemplateMarketplaceInfo getProductTemplateMarketplaceInfo()
ProductTemplate.
This attribute
is applicable when:public void setProductTemplateMarketplaceInfo(ProductTemplateMarketplaceInfo productTemplateMarketplaceInfo)
productTemplateMarketplaceInfo - * Marketplace information of this ProductTemplate.
This attribute
is applicable when:public static org.apache.axis.description.TypeDesc getTypeDesc()
public static org.apache.axis.encoding.Serializer getSerializer(String mechType, Class _javaType, QName _xmlType)
Copyright © 2018. All Rights Reserved.