protected function prepareCallbacks(SubjectInterface $subject, array $callbacks, $type = null)
    {

        // iterate over the array with callbacks and prepare them
        foreach ($callbacks as $key => $callback) {
            // we have to initialize the type only on the first level
            if ($type == null) {
                $type = $key;
            }

            // query whether or not we've an subarry or not
            if (is_array($callback)) {
                $this->prepareCallbacks($subject, $callback, $type);
            } else {
                $subject->registerCallback($this->container->get($callback), $type);
            }
        }
    }
protected function prepareCallbacks(SubjectInterface $subject, array $callbacks, $type = null)
    {

        // iterate over the array with callbacks and prepare them
        foreach ($callbacks as $key => $callback) {
            // we have to initialize the type only on the first level
            if ($type == null) {
                $type = $key;
            }

            // query whether or not we've an subarry or not
            if (is_array($callback)) {
                $this->prepareCallbacks($subject, $callback, $type);
            } else {
                $subject->registerCallback($this->container->get($callback), $type);
            }
        }
    }
protected function prepareCallbacks ( SubjectInterface $ subject , array $ callbacks , $ type = null ) { // iterate over the array with callbacks and prepare them foreach ( $ callbacks as $ key => $ callback ) { // we have to initialize the type only on the first level if ( $ type == null ) { $ type = $ key ; } // query whether or not we've an subarry or not if ( is_array ( $ callback ) ) { $ this -> prepareCallbacks ( $ subject , $ callback , $ type ) ; } else { $ subject -> registerCallback ( $ this -> container -> get ( $ callback ) , $ type ) ; } } }
Prepare the callbacks defined in the system configuration.

@param \TechDivision\Import\Subjects\SubjectInterface $subject   The subject to prepare the callbacks for
@param array                                          $callbacks The array with the callbacks
@param string                                         $type      The actual callback type

@return void
Prepare the callbacks defined in the system configuration .