function _drush_bootstrap_phases

8.0.x bootstrap.inc _drush_bootstrap_phases($function_names = FALSE)
6.x bootstrap.inc _drush_bootstrap_phases($function_names = FALSE, $init_phases_only = FALSE)
7.x bootstrap.inc _drush_bootstrap_phases($function_names = FALSE)
3.x environment.inc _drush_bootstrap_phases($function_names = FALSE)
4.x environment.inc _drush_bootstrap_phases($function_names = FALSE, $init_phases_only = FALSE)
5.x bootstrap.inc _drush_bootstrap_phases($function_names = FALSE, $init_phases_only = FALSE)
master bootstrap.inc _drush_bootstrap_phases($function_names = FALSE)

Returns an array that determines what bootstrap phases are necessary to bootstrap the CMS.

Parameters

bool $function_names: (optional) If TRUE, return an array of method names index by their corresponding phase values. Otherwise return an array of phase values.

Return value

array

See also

\Drush\Boot\Boot::bootstrap_phases()

4 calls to _drush_bootstrap_phases()
drush_bootstrap in includes/bootstrap.inc
Bootstrap Drush to the desired phase.
drush_bootstrap_max in includes/bootstrap.inc
Bootstrap to the highest level possible, without triggering any errors.
drush_bootstrap_to_phase in includes/bootstrap.inc
Bootstrap to the specified phase.
drush_bootstrap_validate in includes/bootstrap.inc
Validate whether a bootstrap phase can be reached.

File

includes/bootstrap.inc, line 165

Code

function _drush_bootstrap_phases($function_names = FALSE) {
  $result = array();

  if ($bootstrap = \Drush::bootstrap()) {
    $result = $bootstrap->bootstrap_phases();
    if (!$function_names) {
      $result = array_keys($result);
    }
  }
  return $result;
}