You are here

public function HijriItem::isEmpty in Hijri 3.0.x

Same name and namespace in other branches
  1. 8.2 src/Plugin/Field/FieldType/HijriItem.php \Drupal\hijri\Plugin\Field\FieldType\HijriItem::isEmpty()
  2. 1.0.x src/Plugin/Field/FieldType/HijriItem.php \Drupal\hijri\Plugin\Field\FieldType\HijriItem::isEmpty()

Determines whether the data structure is empty.

Return value

bool TRUE if the data structure is empty, FALSE otherwise.

Overrides Map::isEmpty

File

src/Plugin/Field/FieldType/HijriItem.php, line 62

Class

HijriItem
Plugin implementation of the 'hijri' field type.

Namespace

Drupal\hijri\Plugin\Field\FieldType

Code

public function isEmpty() {
  $value = $this
    ->get('value')
    ->getValue();
  return $value === NULL || $value === '';
}