protected function getSelectedValue($value, $selected)
    {
        if (is_array($selected)) {
            return in_array($value, $selected, true) ? 'selected' : null;
        }

        return ((string)$value == (string)$selected) ? 'selected' : null;
    }