protected function defineData($var, $type = 'scalar', $options = null, $updateAccept = true)
    {
        if (true === $updateAccept) {
            $this->_addAcceptedType($type, $var);
        }

        if (!empty($options)) {
            $this->defaultOptions[$var] = $options;
        }

        if (!array_key_exists($var, $this->_data)) {
            $this->_data[$var] = [];
            $this->_maxentry[$var] = (!is_null($options) && isset($options['maxentry'])) ? $options['maxentry'] : 1;
            $this->_minentry[$var] = (!is_null($options) && isset($options['minentry'])) ? $options['minentry'] : 0;

            $values = [];
            if (is_array($options) && array_key_exists('default', $options)) {
                $values = (array) $options['default'];

                if ('scalar' !== $type) {
                    foreach ($values as &$value) {
                        $value = new $type(null, $options);
                    }
                    unset($value);
                }
            } else {
                try {
                    $values[] = ('scalar' === $type) ? '' : new $type(null, $options);
                } catch (ClassNotFoundException $ex) {
                    self::onUnknownClassname(sprintf('Unknown classname `%s`.', $type), $ex);
                }
            }

            return $this->__set($var, $values);
        }

        return $this;
    }