private function resolveMode($mode)
    {
        if (!isset($this->modeResolers[$mode])) {
            $this->modeResolvers[$mode] = $this->createModeResolver($mode);
        }

        return $this->modeResolvers[$mode];
    }