public function IconFieldItem::isEmpty in Icon API 8
Determines whether the data structure is empty.
Return value
bool TRUE if the data structure is empty, FALSE otherwise.
Overrides Map::isEmpty
File
- modules/
icon_field/ src/ Plugin/ Field/ FieldType/ IconFieldItem.php, line 56 - Contains \Drupal\Icon\Plugin\field\field_type\IconFieldItem.
Class
- IconFieldItem
- Plugin implementation of the 'IconFieldItem' field type.
Namespace
Drupal\icon_field\Plugin\Field\FieldTypeCode
public function isEmpty() {
$value = $this
->get('icon')
->getValue();
return $value === NULL || $value === '';
}