class CurrencyAmountFormatter in Currency 8.3
Defines a currency amount formatter plugin definition.
If a plugin exposes configuration, it SHOULD also provide a configuration schema for this configuration of which the name is `plugin.plugin_configuration.currency_amount_formatter.[plugin_id]`, where `[plugin_id]` is the plugin's ID.
Hierarchy
- class \Drupal\Component\Annotation\Plugin implements AnnotationInterface
- class \Drupal\currency\Annotation\CurrencyAmountFormatter
Expanded class hierarchy of CurrencyAmountFormatter
1 file declares its use of CurrencyAmountFormatter
- AmountFormatterManager.php in src/
Plugin/ Currency/ AmountFormatter/ AmountFormatterManager.php
2 classes are annotated with CurrencyAmountFormatter
- Basic in src/
Plugin/ Currency/ AmountFormatter/ Basic.php - Formats amounts using string translation and number_format().
- Intl in modules/
currency_intl/ src/ Plugin/ Currency/ AmountFormatter/ Intl.php - Formats amounts using PHP's Intl extension.
File
- src/
Annotation/ CurrencyAmountFormatter.php, line 17
Namespace
Drupal\currency\AnnotationView source
class CurrencyAmountFormatter extends Plugin {
/**
* The translated human-readable plugin name (optional).
*
* @var string
*/
public $description = '';
/**
* The plugin ID.
*
* @var string
*/
public $id;
/**
* The translated human-readable plugin name.
*
* @var string
*/
public $label;
}
Members
Name | Modifiers | Type | Description | Overrides |
---|---|---|---|---|
CurrencyAmountFormatter:: |
public | property | The translated human-readable plugin name (optional). | |
CurrencyAmountFormatter:: |
public | property | The plugin ID. | |
CurrencyAmountFormatter:: |
public | property | The translated human-readable plugin name. | |
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 |