Sets multiple HTML table attributes at once.

@param array $attributes
@return $this
339819
public function setTableAttributes(array $attributes)
    {
        foreach ($attributes as $attribute => $value) {
            $this->tableAttributes[$attribute] = $value;
        }

        return $this;
    }
547158
public function setAttributes()
    {
        $attributes = func_get_args();
        if (count($attributes)) {
            if (count($attributes) == 1 && is_array($attributes[0])) {
                $attributes = $attributes[0];
            }
            $this->attributes = $attributes;
        }

        return $this;
    }
1080337
public function set($attributes = array())
    {
        $this->attributes = array_replace_recursive($this->attributes, $attributes);

        return $this->attributes;
    }
1133756
public function setAttributes($attributes)
    {
        foreach ($attributes as $attribute => $value) {
            if ($attribute === 'class') {
                $this->addClass($value);
                continue;
            }

            if (is_int($attribute)) {
                $attribute = $value;
                $value = '';
            }

            $this->setAttribute($attribute, (string) $value);
        }

        return $this;
    }
1324443
public function mergeWith(self $attributes)
    {
        $this->attributes = array_merge($this->attributes, $attributes->attributes);
        $this->classes = array_merge($this->classes, $attributes->classes);

        return $this;
    }
850696
public function setAttributes($attributes)
    {
        $attributes = self::prepareAttributes($attributes);
        $watched    = array();
        foreach ($this->watchedAttributes as $watchedKey) {
            if (isset($attributes[$watchedKey])) {
                $this->setAttribute($watchedKey, $attributes[$watchedKey]);
                unset($attributes[$watchedKey]);
            } else {
                $this->removeAttribute($watchedKey);
            }
            if (isset($this->attributes[$watchedKey])) {
                $watched[$watchedKey] = $this->attributes[$watchedKey];
            }
        }
        $this->attributes = array_merge($watched, $attributes);
        return $this;
    }
1147987
public static function fromArray(array $attributes) {
		unset($attributes['id']);
		
		$attributesObject = new self();
		
		foreach ($attributes as $key => $value) {
			$attributesObject->add($key, $value);
		}
		
		return $attributesObject;
	}
803799
public function set(array $attributes)
    {
        collect($attributes)->each(function ($value, $key) {
            $this->setKeyValue($key, $value);
        });

        // If we were working with eagerly-loaded relation,
        // we need to reload its data to be sure that we
        // are working only with the actual settings.

        if ($this->resource->relationLoaded('propertyBag')) {
            $this->resource->load('propertyBag');
        }

        return $this->sync();
    }
1166243
public function setAttributes($attributes)
    {
        if ($attributes === null) {
            $this->attributes = [];

            return $this;
        }

        if (is_array($attributes)) {
            $this->attributes = $attributes;

            return $this;
        }

        $attributes = explode(',', $attributes);
        $attributes = $this->relationsToArray($attributes);

        $this->attributes = $attributes;

        return $this;
    }
896827
public function style(Array $attributes) : Table
    {
        $attribute = '';

        foreach( $attributes as $key => $values )
        {
            if( is_numeric($key) )
            {
                $key = $values;
            }

            $attribute .= ' '.$key.':'.$values.';';
        }

        $this->attr['style'] = $attribute;

        return $this;
    }
851286
public function registerCustomAttributes($attributes) 
    {
        if( is_string($attributes) ) {
            $attributes = explode(' ',$attributes);
        }
        $this->customAttributes = array_merge( $this->customAttributes , (array) $attributes );
        return $this;
    }
972832
public function setAttributes(Array $attributes) {

		foreach($attributes as $k => $v) {
			$this->setAttribute($k, $v);
		}
		return $this;

	}
1325635
public function remove($attributes)
    {
        foreach ((array) $attributes as $attribute) {
            unset($this->defaults[$attribute],
                $this->types[$attribute],
                $this->requires[$attribute],
                $this->notNullables[$attribute]);
        }

        return $this;
    }
578153
public function setAttributes(array $attributes): void
    {
        $this->checkAttributeAssignable(array_keys($attributes));

        $this->setRawAttributes($attributes);
    }
512571
public function syncOriginalAttributes($attributes)
    {
        $attributes = is_array($attributes) ? $attributes : func_get_args();

        foreach ($attributes as $attribute) {
            $this->original[$attribute] = $this->attributes[$attribute];
        }

        return $this;
    }
482896
public function row(array $attributes = array())
        {
            $row = new self();

            if (count($attributes)) {
                $row->setAttributes($attributes);
            }

            return $row;
        }
1116222
public function setAttributes( $attributes = array() )
	{
		if( !empty( $attributes['class'] ) && is_string( $attributes['class'] ) )
			$attributes['class']	= explode( ' ', $attributes['class'] );
		$this->addAttributes( $attributes );
	}