public function LinkItem::isEmpty in Zircon Profile 8.0
Same name and namespace in other branches
- 8 core/modules/link/src/Plugin/Field/FieldType/LinkItem.php \Drupal\link\Plugin\Field\FieldType\LinkItem::isEmpty()
Determines whether the data structure is empty.
Return value
bool TRUE if the data structure is empty, FALSE otherwise.
Overrides Map::isEmpty
File
- core/
modules/ link/ src/ Plugin/ Field/ FieldType/ LinkItem.php, line 154 - Contains \Drupal\link\Plugin\Field\FieldType\LinkItem.
Class
- LinkItem
- Plugin implementation of the 'link' field type.
Namespace
Drupal\link\Plugin\Field\FieldTypeCode
public function isEmpty() {
$value = $this
->get('uri')
->getValue();
return $value === NULL || $value === '';
}