diff --git a/includes/entity.wrapper.inc b/includes/entity.wrapper.inc index d5d22ac..100df6c 100644 --- a/includes/entity.wrapper.inc +++ b/includes/entity.wrapper.inc @@ -115,6 +115,20 @@ abstract class EntityMetadataWrapper { } /** + * Returns whether data is available to work with. + * + * Exposes the EntityMetadataWrapper::dataAvailable() method result. + * + * @return + * If we operate without any data TRUE, else FALSE. + * + * @see EntityMetadataWrapper::dataAvailable() + */ + public function isEmpty() { + return !$this->dataAvailable(); + } + + /** * Set a new data value. */ public function set($value) {