Add CSS class to element. Previously added classes are not affected.
Multiple CSS classes can also be added if passed as space separated
string or array of class names.

@param string|array $class CSS class name or array of class names

@return $this
761272
public function addClass($class)
    {
        if (is_array($class)) {
            foreach ($class as $c) {
                $this->addClass($class);
            }

            return $this;
        }
        $this->template->append('class', ' '.$class);

        return $this;
    }
1212064
public function addClass($class)
    {
        $reflectedclass = Smd\Service::read($this, $class);
        if ( $reflectedclass !== false ) {
            $this->services[] = $reflectedclass;
        }
        return $this;
    }
1249933
public function addClass(&$class)
    {
        if (isset($this->_classes[$class->name()])) {
            $phpdoctor =& $this->_root->phpdoctor();
            echo "\n";
            $phpdoctor->warning('Found class '.$class->name().' again, overwriting previous version');
        }
        $this->_classes[$class->name()] =& $class;
    }
421838
public function setEmbedClass($class)
    {
        $classes = ($class) ? explode(' ', $class) : [];
        foreach ($classes as $key => $value) {
            $this->classes[$value] = $value;
        }
        return $this->owner;
    }
1349143
public function addClass(string $value) : self
    {
        $class = trim($this->attributes['class']);
        $this->attributes['class'] = trim($class . ' ' . trim($value));
        return $this;
    }
318954
public function setClass($class)
    {
        foreach ($this->results as $name) {
            $this->columns->offsetGet($name)->setClass($class);
        }
    }
256095
public function addClass($class)
    {
        if (! $this->hasClass($class)) {
            $this->set('class', trim((string) $this->get('class') . ' ' . $class));
        }

        return $this;
    }
963752
public function addTableClass($class)
    {
        $class = is_array($class) ? implode(' ', $class) : $class;
        $currentClass = Arr::get(array_change_key_case($this->tableAttributes), 'class');

        $classes = preg_split('#\s+#', $currentClass . ' ' . $class, null, PREG_SPLIT_NO_EMPTY);
        $class = implode(' ', array_unique($classes));

        return $this->setTableAttribute('class', $class);
    }
365281
public function removeClass($class)
    {
        $classes = $this->get('class');
        if ($classes) {
            $classes = trim(preg_replace('/(^| ){1}' . $class . '( |$){1}/i', ' ', $classes));
            $this->set('class', $classes);
        }

        return $this;
    }
173239
public function addClass($class)
    {
        if (is_array($class)) {
            $class = implode(' ', $class);
        }

        if (!$this->class) {
            $this->class = [];
        }

        if (is_string($this->class)) {
            throw new Exception(['Property $class should always be array', 'object' => $this, 'class' => $this->class]);
        }

        $this->class = array_merge($this->class, explode(' ', $class));

        return $this;
    }
472186
public function addClass($class)
    {
        $this->setOption(self::OPTION_METHOD, "addClass");
        $this->setOption(self::OPTION_ADD_CLASS, $class);

        return $this;
    }
803096
public function remove_html_class( $class )
    {
        $i = 0;
        foreach( $this->html_classes as $c )
        {
            if( $c === $class )
            {
                array_splice($this->html_classes,$i,1);
                break;
            }
            $i++;
        }
    }
811339
public function css( $cssClasses )
    {
        if ( ! $cssClasses )
        {
            return $this;
        }

        $cssClasses = explode( ' ', $cssClasses );

        foreach ( $cssClasses as $cssClass )
        {
            if ( $cssClass && false === in_array( $cssClass, $this->cssClasses ) )
            {
                $this->cssClasses[] = $cssClass;
            }
        }

        return $this;
    }
831462
public function addFormFieldCssClass($cssClass)
    {
        $cssClass = array_merge($this->formFieldCssClass, $this->parseCssClasses($cssClass));
        $this->formFieldCssClass = array_unique($cssClass);
        return $this;
    }
840799
public function addClass($class) {

		// classes array
		if (is_array($class)) {
			
			// adds all of them
			foreach ($class as $c) {
				if (!in_array($c, $this->class)) {
					$this->class[] = $c;
				}
			}
			
		// single class
		} else if (!in_array($class, $this->class)) {
			
			$this->class[] = $class;
			
		}

		return $this;

	}
1162203
public function addClass ($class)
    {
        $targetArray = &$this->customClasses;
        if (!is_array($class))
            $targetArray[] = $class;
        else
            $targetArray = array_merge($targetArray, $class);
        return $this;
    }
284296
public function appendStdClass(stdClass $class)
    {
        $this->appendArray(get_object_vars($class));

        if ($this->_objectCreation) {
            return $this->_afterAppendDataToNewObject();
        }
        return $this;
    }