Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.
Info
titleInnomatic 7 architectural change

Innomatic 7.x will use Symfony Dependency Injection Container in place of the Innomatic Container.

Innomatic features Inversion of Control through a dependency injection container in \Innomatic\Core\InnomaticContainer.

...

Code Block
languagephp
// InnomaticContainer is a singleton as defined in \Innomatic\Util\Singleton
$container = \Innomatic\Core\InnomaticContainer::instance('\Innomatic\Core\InnomaticContainer');

// Get current tenant
$tenant = $container->getCurrentTenant(); 

// Get current tenant user
$tenant = $container->getCurrentUser();

// Get root database
$rootDataAccess = $container->getDataAccess();

Next: Step 5: Code classes