public function onResolving(Closure $callback, $priority = 0)
    {
        if (!isset($this->callbacks[$priority])) {

            $this->callbacks[$priority] = array();

        }
        $this->callbacks[$priority][] = $callback;
    }