@Generated(value="com.amazonaws:aws-java-sdk-code-generator") public class Promotion extends Object implements Serializable, Cloneable, StructuredPojo
Contains information on a promotion. A promotion defines additional business rules that apply to a configurable subset of recommended items.
Constructor and Description |
---|
Promotion() |
Modifier and Type | Method and Description |
---|---|
Promotion |
addFilterValuesEntry(String key,
String value)
Add a single FilterValues entry
|
Promotion |
clearFilterValuesEntries()
Removes all the entries added into FilterValues.
|
Promotion |
clone() |
boolean |
equals(Object obj) |
String |
getFilterArn()
The Amazon Resource Name (ARN) of the filter used by the promotion.
|
Map<String,String> |
getFilterValues()
The values to use when promoting items.
|
String |
getName()
The name of the promotion.
|
Integer |
getPercentPromotedItems()
The percentage of recommended items to apply the promotion to.
|
int |
hashCode() |
void |
marshall(ProtocolMarshaller protocolMarshaller)
Marshalls this structured data using the given
ProtocolMarshaller . |
void |
setFilterArn(String filterArn)
The Amazon Resource Name (ARN) of the filter used by the promotion.
|
void |
setFilterValues(Map<String,String> filterValues)
The values to use when promoting items.
|
void |
setName(String name)
The name of the promotion.
|
void |
setPercentPromotedItems(Integer percentPromotedItems)
The percentage of recommended items to apply the promotion to.
|
String |
toString()
Returns a string representation of this object.
|
Promotion |
withFilterArn(String filterArn)
The Amazon Resource Name (ARN) of the filter used by the promotion.
|
Promotion |
withFilterValues(Map<String,String> filterValues)
The values to use when promoting items.
|
Promotion |
withName(String name)
The name of the promotion.
|
Promotion |
withPercentPromotedItems(Integer percentPromotedItems)
The percentage of recommended items to apply the promotion to.
|
public void setName(String name)
The name of the promotion.
name
- The name of the promotion.public String getName()
The name of the promotion.
public Promotion withName(String name)
The name of the promotion.
name
- The name of the promotion.public void setPercentPromotedItems(Integer percentPromotedItems)
The percentage of recommended items to apply the promotion to.
percentPromotedItems
- The percentage of recommended items to apply the promotion to.public Integer getPercentPromotedItems()
The percentage of recommended items to apply the promotion to.
public Promotion withPercentPromotedItems(Integer percentPromotedItems)
The percentage of recommended items to apply the promotion to.
percentPromotedItems
- The percentage of recommended items to apply the promotion to.public void setFilterArn(String filterArn)
The Amazon Resource Name (ARN) of the filter used by the promotion. This filter defines the criteria for promoted items. For more information, see Promotion filters.
filterArn
- The Amazon Resource Name (ARN) of the filter used by the promotion. This filter defines the criteria for
promoted items. For more information, see Promotion
filters.public String getFilterArn()
The Amazon Resource Name (ARN) of the filter used by the promotion. This filter defines the criteria for promoted items. For more information, see Promotion filters.
public Promotion withFilterArn(String filterArn)
The Amazon Resource Name (ARN) of the filter used by the promotion. This filter defines the criteria for promoted items. For more information, see Promotion filters.
filterArn
- The Amazon Resource Name (ARN) of the filter used by the promotion. This filter defines the criteria for
promoted items. For more information, see Promotion
filters.public Map<String,String> getFilterValues()
The values to use when promoting items. For each placeholder parameter in your promotion's filter expression, provide the parameter name (in matching case) as a key and the filter value(s) as the corresponding value. Separate multiple values for one parameter with a comma.
For filter expressions that use an INCLUDE
element to include items, you must provide values for all
parameters that are defined in the expression. For filters with expressions that use an EXCLUDE
element to exclude items, you can omit the filter-values
. In this case, Amazon Personalize doesn't
use that portion of the expression to filter recommendations.
For more information on creating filters, see Filtering recommendations and user segments.
For filter expressions that use an INCLUDE
element to include items, you must provide values
for all parameters that are defined in the expression. For filters with expressions that use an
EXCLUDE
element to exclude items, you can omit the filter-values
. In this case,
Amazon Personalize doesn't use that portion of the expression to filter recommendations.
For more information on creating filters, see Filtering recommendations and user segments.
public void setFilterValues(Map<String,String> filterValues)
The values to use when promoting items. For each placeholder parameter in your promotion's filter expression, provide the parameter name (in matching case) as a key and the filter value(s) as the corresponding value. Separate multiple values for one parameter with a comma.
For filter expressions that use an INCLUDE
element to include items, you must provide values for all
parameters that are defined in the expression. For filters with expressions that use an EXCLUDE
element to exclude items, you can omit the filter-values
. In this case, Amazon Personalize doesn't
use that portion of the expression to filter recommendations.
For more information on creating filters, see Filtering recommendations and user segments.
filterValues
- The values to use when promoting items. For each placeholder parameter in your promotion's filter
expression, provide the parameter name (in matching case) as a key and the filter value(s) as the
corresponding value. Separate multiple values for one parameter with a comma.
For filter expressions that use an INCLUDE
element to include items, you must provide values
for all parameters that are defined in the expression. For filters with expressions that use an
EXCLUDE
element to exclude items, you can omit the filter-values
. In this case,
Amazon Personalize doesn't use that portion of the expression to filter recommendations.
For more information on creating filters, see Filtering recommendations and user segments.
public Promotion withFilterValues(Map<String,String> filterValues)
The values to use when promoting items. For each placeholder parameter in your promotion's filter expression, provide the parameter name (in matching case) as a key and the filter value(s) as the corresponding value. Separate multiple values for one parameter with a comma.
For filter expressions that use an INCLUDE
element to include items, you must provide values for all
parameters that are defined in the expression. For filters with expressions that use an EXCLUDE
element to exclude items, you can omit the filter-values
. In this case, Amazon Personalize doesn't
use that portion of the expression to filter recommendations.
For more information on creating filters, see Filtering recommendations and user segments.
filterValues
- The values to use when promoting items. For each placeholder parameter in your promotion's filter
expression, provide the parameter name (in matching case) as a key and the filter value(s) as the
corresponding value. Separate multiple values for one parameter with a comma.
For filter expressions that use an INCLUDE
element to include items, you must provide values
for all parameters that are defined in the expression. For filters with expressions that use an
EXCLUDE
element to exclude items, you can omit the filter-values
. In this case,
Amazon Personalize doesn't use that portion of the expression to filter recommendations.
For more information on creating filters, see Filtering recommendations and user segments.
public Promotion addFilterValuesEntry(String key, String value)
public Promotion clearFilterValuesEntries()
public String toString()
toString
in class Object
Object.toString()
public void marshall(ProtocolMarshaller protocolMarshaller)
StructuredPojo
ProtocolMarshaller
.marshall
in interface StructuredPojo
protocolMarshaller
- Implementation of ProtocolMarshaller
used to marshall this object's data.