Ejemplo n.º 1
0
 /**
  * Make a Acetone container
  *
  * @return Container
  */
 public static function make($app = null)
 {
     if (!$app) {
         $app = new Container();
     }
     $serviceProvider = new static($app);
     // Bind classes
     $app = $serviceProvider->bindCoreClasses($app);
     $app = $serviceProvider->bindClasses($app);
     return $app;
 }
Ejemplo n.º 2
0
 /**
  * Make a Rocketeer container
  *
  * @param Container $app
  *
  * @return Container
  */
 public static function make($app = null)
 {
     if (!$app) {
         $app = new Container();
     }
     $serviceProvider = new static($app);
     // Bind core paths and classes
     $app = $serviceProvider->bindPaths($app);
     $app = $serviceProvider->bindCoreClasses($app);
     // Bind Rocketeer's classes
     $app = $serviceProvider->bindClasses($app);
     $app = $serviceProvider->bindScm($app);
     // Load the user's events and tasks
     $app = $serviceProvider->loadFileOrFolder($app, 'tasks');
     $app = $serviceProvider->loadFileOrFolder($app, 'events');
     // Bind commands
     $app = $serviceProvider->bindCommands($app);
     return $app;
 }