src/helpers/BaseYaml.php
/**
     * Ensure that a definition has been set for the specified dependency
     *
     * @param  string $class class name of the dependency
     *
     * @param  string $defaultConfigMethod name of static method that provides
     *     our default configuration array for the dependency.
     */
Ensure that a definition has been set for the specified dependency
@param  string $class class name of the dependency

@param  string $defaultConfigMethod name of static method that provides
our default configuration array for the dependency.
Ensure that a definition has been set for the specified dependency @param string $class class name of the dependency @param string $defaultConfigMethod name of static method that provides our default configuration array for the dependency .
private static function ensureDependencyDefined($class, $defaultConfigMethod)
    {
        if (Yii::$container->has($class)) {
            return;
        }
        Yii::$container->setDefinitions([
            $class => static::getDependencyDefinition($class, $defaultConfigMethod),
        ]);
    }
private static function ensureDependencyDefined ( $ class , $ defaultConfigMethod ) { if ( Yii :: $ container -> has ( $ class ) ) { return ; } Yii :: $ container -> setDefinitions ( [ $ class => static :: getDependencyDefinition ( $ class , $ defaultConfigMethod ) , ] ) ; }
Ensure that a definition has been set for the specified dependency
 @param  string $class class name of the dependency
Ensure that a definition has been set for the specified dependency @param string $class class name of the dependency