You are here

function drush_commerce_generate in Commerce Bulk 8

Command callback. Generate a number of elements.

1 string reference to 'drush_commerce_generate'
commerce_generate_drush_command in modules/commerce_generate/commerce_generate.drush.inc
Implements hook_drush_command().

File

modules/commerce_generate/commerce_generate.drush.inc, line 53
Integration with Drush8.

Code

function drush_commerce_generate() {
  $params = func_get_args();
  $plugin_id = array_shift($params);
  $instance_and_values = drupal_static('drush_devel_generate_generate_validate');

  /** @var DevelGenerateBaseInterface $instance */
  $instance = $instance_and_values[$plugin_id]['instance'];
  $values = $instance_and_values[$plugin_id]['values'];
  $instance
    ->generate($values);
}