Adds categories.
@param string|string[] $values
344203
public function addCategoryValues($values)
    {
        $this->_categoryValues = array_unique(array_merge($this->getCategoryValues(true), $this->filterCategoryValues($values)));
    }
1003295
function setValues (array $values = array())
    {
        foreach ($this->getFields() as $field)
            if (array_key_exists($field->getName(), $values))
                $field->setValue($values[$field->getName()]);
        foreach ($this->dataFields as $dataKey => $dataVal)
            if (array_key_exists($dataKey, $values))
                $this->dataFields[$dataKey] = $values[$dataKey];
    }
1294527
public function add(string $path, array $values): void
    {
        $get = (array)$this->get($path);
        $this->set($path, $this->arrayMergeRecursiveDistinct($get, $values));
    }
112708
public static function createFromArray(array $values)
    {
        $category = new self($values['title'], isset($values['domain']) ? $values['domain'] : null);

        return $category;
    }
870381
public function fit(array $values) : void
    {
        if (empty($values)) {
            throw new InvalidArgumentException('Strategy must be fit with'
                . ' at least 1 value.');
        }

        $categories = array_values(array_unique($values));

        $this->categories = $categories;
        $this->k = count($categories);
    }
128226
public function setValue($values): void
  {
    foreach ($this->controls as $control)
    {
      $control->setValuesBase($values);
    }
  }
1209893
public function addAnnotations($values)
    {
        // TODO interface
        if (method_exists($values, 'getPublicAnnotations')) {
            $this->addAnnotations($values->getPublicAnnotations());
        } else {
            foreach ($values as $name => $value) {
                $this->addAnnotation($name, $value);
            }
        }
    }
340015
protected function setFieldset($values)
    {
        foreach ($values as $name => $field) {
            $this->fields[$name] = $field;
        }
    }
188780
public function addLanguageValues($values)
    {
        $this->_languageValues = array_unique(array_merge($this->getLanguageValues(true), $this->filterLanguageValues($values)));
    }
871740
public function filterCategoryValues($values)
    {
        return array_unique(preg_split(
            '/\s*,\s*/u',
            preg_replace('/\s+/u', ' ', is_array($values) ? implode(',', $values) : $values),
            -1,
            PREG_SPLIT_NO_EMPTY
        ));
    }
299950
public static function setSettings( array $values )
	{
		foreach ($values as $name => $value)
			self::setSetting($name, $value);
	}
819956
public function setValues($values)
    {
        if (!is_array($values)) {
            $values = preg_split('/,\s*/', $values);
        }
        $this->values = $values;

        return $this;
    }
1210011
public function bindValues($values): void
    {
        $params = func_get_args();
        if (isset($params[0]) && is_array($params[0])) {
            $this->bindedValues = new \ArrayObject($params[0]);
        } else {
            $this->bindedValues = new \ArrayObject($params);
        }
    }
1233901
public function addValue($value)
    {
        $values = $this->getValues();
        array_push($values, $value);
        $this->setValues($values);
    }
343326
public function bindValues($values)
    {
        foreach($values as $k => $v)
        {
            $this->binds[$k] = $v;
        }
        return $this;
    }
1013088
public function setValues(array $values)
    {
        foreach ($values as $key => $value) {
            if (is_integer($value)) {
                // cast integer values silenty to a double value.
                $values[$key] = $value = (double) $value;
            }
            $this->checkType('double', $value, true);
        }
        parent::setValues($values);
    }
1085203
public function setValues(array $values = array())
    {
        foreach ($values as $k => $v) {
            $this->set($k, $v);
        }

        return $this;
    }