class CommercePromotionOffer in Commerce Core 8.2
Defines the promotion offer plugin annotation object.
Plugin namespace: Plugin\Commerce\PromotionOffer.
Hierarchy
- class \Drupal\Component\Annotation\Plugin implements AnnotationInterface
- class \Drupal\commerce_promotion\Annotation\CommercePromotionOffer
Expanded class hierarchy of CommercePromotionOffer
6 classes are annotated with CommercePromotionOffer
- BuyXGetY in modules/
promotion/ src/ Plugin/ Commerce/ PromotionOffer/ BuyXGetY.php - Provides the "Buy X Get Y" offer for orders.
- CombinationOffer in modules/
promotion/ src/ Plugin/ Commerce/ PromotionOffer/ CombinationOffer.php - Provides the 'combination_offer' offer plugin.
- OrderFixedAmountOff in modules/
promotion/ src/ Plugin/ Commerce/ PromotionOffer/ OrderFixedAmountOff.php - Provides the fixed amount off offer for orders.
- OrderItemFixedAmountOff in modules/
promotion/ src/ Plugin/ Commerce/ PromotionOffer/ OrderItemFixedAmountOff.php - Provides the percentage off offer for order items.
- OrderItemPercentageOff in modules/
promotion/ src/ Plugin/ Commerce/ PromotionOffer/ OrderItemPercentageOff.php - Provides the percentage off offer for order items.
File
- modules/
promotion/ src/ Annotation/ CommercePromotionOffer.php, line 14
Namespace
Drupal\commerce_promotion\AnnotationView source
class CommercePromotionOffer extends Plugin {
/**
* The plugin ID.
*
* @var string
*/
public $id;
/**
* The label of the plugin.
*
* @var \Drupal\Core\Annotation\Translation
*
* @ingroup plugin_translatable
*/
public $label;
/**
* The offer entity type ID.
*
* This is the entity type ID of the entity passed to the plugin during execution.
* For example: 'commerce_order'.
*
* @var string
*/
public $entity_type;
}
Members
Name | Modifiers | Type | Description | Overrides |
---|---|---|---|---|
CommercePromotionOffer:: |
public | property | The offer entity type ID. | |
CommercePromotionOffer:: |
public | property | The plugin ID. | |
CommercePromotionOffer:: |
public | property | The label of the plugin. | |
Plugin:: |
protected | property | The plugin definition read from the class annotation. | 1 |
Plugin:: |
public | function |
Gets the value of an annotation. Overrides AnnotationInterface:: |
5 |
Plugin:: |
public | function |
Gets the class of the annotated class. Overrides AnnotationInterface:: |
|
Plugin:: |
public | function |
Gets the unique ID for this annotated class. Overrides AnnotationInterface:: |
|
Plugin:: |
public | function |
Gets the name of the provider of the annotated class. Overrides AnnotationInterface:: |
|
Plugin:: |
protected | function | Parses an annotation into its definition. | |
Plugin:: |
public | function |
Sets the class of the annotated class. Overrides AnnotationInterface:: |
|
Plugin:: |
public | function |
Sets the name of the provider of the annotated class. Overrides AnnotationInterface:: |
|
Plugin:: |
public | function | Constructs a Plugin object. | 2 |