public function loadAndRegister(Aspect $aspect): void
    {
        $loadedItems = $this->load($aspect);
        foreach ($loadedItems as $itemId => $item) {
            if ($item instanceof Pointcut) {
                $this->container->registerPointcut($item, $itemId);
            }
            if ($item instanceof Advisor) {
                $this->container->registerAdvisor($item, $itemId);
            }
        }

        $aspectClass = get_class($aspect);
        $this->loadedAspects[$aspectClass] = $aspectClass;
    }
public function loadAndRegister(Aspect $aspect): void
    {
        $loadedItems = $this->load($aspect);
        foreach ($loadedItems as $itemId => $item) {
            if ($item instanceof Pointcut) {
                $this->container->registerPointcut($item, $itemId);
            }
            if ($item instanceof Advisor) {
                $this->container->registerAdvisor($item, $itemId);
            }
        }

        $aspectClass = get_class($aspect);
        $this->loadedAspects[$aspectClass] = $aspectClass;
    }
public function loadAndRegister ( Aspect $ aspect ) : void { $ loadedItems = $ this -> load ( $ aspect ) ; foreach ( $ loadedItems as $ itemId => $ item ) { if ( $ item instanceof Pointcut ) { $ this -> container -> registerPointcut ( $ item , $ itemId ) ; } if ( $ item instanceof Advisor ) { $ this -> container -> registerAdvisor ( $ item , $ itemId ) ; } } $ aspectClass = get_class ( $ aspect ) ; $ this -> loadedAspects [ $ aspectClass ] = $ aspectClass ; }
Loads and register all items of aspect in the container
Loads and register all items of aspect in the container