protected static function ModuleBuilderComponentFormBase::getCompoundPropertyItemCount in Module Builder 7.2
Gets the item count for a compound property from the form state.
Parameters
$form_state: The form state.
array $property_address: The value address.
Return value
int The item count.
3 calls to ModuleBuilderComponentFormBase::getCompoundPropertyItemCount()
- ModuleBuilderComponentFormBase::decrementCompoundPropertyItemCount in includes/
module_builder.form.inc - Decrements the item count for a compound property from the form state.
- ModuleBuilderComponentFormBase::elementCompound in includes/
module_builder.form.inc - Set form element properties specific to compound component properties.
- ModuleBuilderComponentFormBase::incrementCompoundPropertyItemCount in includes/
module_builder.form.inc - Increments the item count for a compound property from the form state.
File
- includes/
module_builder.form.inc, line 885
Class
- ModuleBuilderComponentFormBase
- Backport of ComponentFormBase from 8.x-3.x version.
Code
protected static function getCompoundPropertyItemCount($form_state, $property_address) {
$property_address_key = implode(':', $property_address);
$item_count = $form_state
->get([
'item_count',
$property_address_key,
]);
return $item_count;
}