function SandwichBase::calories
Same name in other branches
- 8.x-1.x plugin_type_example/src/SandwichBase.php \Drupal\plugin_type_example\SandwichBase::calories()
- 4.0.x modules/plugin_type_example/src/SandwichBase.php \Drupal\plugin_type_example\SandwichBase::calories()
Overrides SandwichInterface::calories
File
-
modules/
plugin_type_example/ src/ SandwichBase.php, line 43
Class
- SandwichBase
- A base class to help developers implement their own sandwich plugins.
Namespace
Drupal\plugin_type_exampleCode
public function calories() {
// Retrieve the @calories property from the annotation and return it.
return (double) $this->pluginDefinition['calories'];
}