public function sortOptions()
    {
        $options = array();

        $expectedOptions = $this->di->get('option')->getExpectedOrder();

        foreach ($expectedOptions as $pos => $key) {
            if (array_key_exists($pos, $this->options)) {
                $options[$key] = $this->di->get('option')->validate($key, $this->options[$pos]);
            } else {
                $this->di->get('option')->validate($key, null);
            }
        }

        $this->di->get('option')->load($options);
    }