function drush_outputformat::data_type

8.0.x outputformat.drush.inc drush_outputformat::data_type($metadata)
6.x outputformat.drush.inc drush_outputformat::data_type($metadata)
7.x outputformat.drush.inc drush_outputformat::data_type($metadata)
master outputformat.drush.inc drush_outputformat::data_type($metadata)
1 call to drush_outputformat::data_type()
drush_outputformat_list::format in commands/core/outputformat/list.inc

File

commands/core/outputformat.drush.inc, line 370
Core drush output formats.

Class

drush_outputformat
Interface for output format engines.

Code

function data_type($metadata) {
  if (isset($metadata['metameta']['require-engine-capability']) && is_array($metadata['metameta']['require-engine-capability'])) {
    return $metadata['metameta']['require-engine-capability'][0];
  }
  if (isset($metadata['require-engine-capability']) && is_array($metadata['require-engine-capability'])) {
    return $metadata['require-engine-capability'][0];
  }
  return 'unspecified';
}