Get the model attributes on the WordPress object
that have changed compared to the model's
original attributes.

@return array
359754
public function get_changed_wp_object_attributes() {
		$changed = array();

		foreach ( $this->get_wp_object_keys() as $key ) {
			if ( $this->get_attribute( $key ) !==
				 $this->get_original_attribute( $key )
			) {
				$changed[ $key ] = $this->get_attribute( $key );
			}
		}

		return $changed;
	}
1102857
protected function getDeletedEventAttributes(): array
    {
        $old = [];

        foreach ($this->attributes as $attribute => $value) {
            if ($this->isAttributeAuditable($attribute)) {
                $old[$attribute] = $value;
            }
        }

        return [
            $old,
            [],
        ];
    }
666090
function attributes()
    {
        $attributes = array();
        $item = $this->InternalAttributes['item'];
        if ( is_array( $item ) )
        {
            $attributes = array_keys( $item );
        }
        else if ( is_object( $item ) and
                  method_exists( $item, 'attributes' ) )
        {
            $attributes = $item->attributes();
        }
        $attributes = array_merge( $this->InternalAttributes, $attributes );
        $attributes = array_unique( $attributes );
        return $attributes;
    }
1249602
protected function getDataAttrs(): array
    {
        $attrs = array_filter($this->html->getAttributes(), static function ($v, $k) {
            return strpos($k, 'data-') === 0;
        }, ARRAY_FILTER_USE_BOTH);

        $dataAttrs = [];

        foreach ($attrs as $key => $value) {
            $key = substr($key, 5);

            $dataAttrs[$key] = $value;
        }

        return $dataAttrs;
    }
947928
public function attributes()
    {
        $def = $this->definition();
        $attrs = array_keys( $def["fields"] );
        if ( isset( $def["function_attributes"] ) )
            $attrs = array_unique( array_merge( $attrs, array_keys( $def["function_attributes"] ) ) );
        if ( isset( $def["functions"] ) )
            $attrs = array_unique( array_merge( $attrs, array_keys( $def["functions"] ) ) );
        return $attrs;
    }
511420
public function getReferencedAttributes()
    {
        $objMetaModel  = $this->getMetaModel();
        $objAttribute  = $objMetaModel->getAttributeById($this->get('attr_id'));
        $objAttribute2 = $objMetaModel->getAttributeById($this->get('attr_id2'));
        $arrResult     = [];

        if ($objAttribute) {
            $arrResult[] = $objAttribute->getColName();
        }

        if ($objAttribute2) {
            $arrResult[] = $objAttribute2->getColName();
        }

        return $arrResult;
    }
1255227
public function getDirty()
    {
        $dirty = [];

        foreach ($this->attributes as $key => $value) {
            if (! array_key_exists($key, $this->original)) {
                $dirty[$key] = $value;
            } elseif ($value !== $this->original[$key] &&
                                 ! $this->originalIsNumericallyEquivalent($key)) {
                $dirty[$key] = $value;
            }
        }

        return $dirty;
    }
880679
public function getAttributes()
    {
        if ($this->_oAttributeList === null) {
            $this->_oAttributeList = $this->newAttributelist();
            $this->_oAttributeList->loadAttributes($this->getId(), $this->getParentId());
        }

        return $this->_oAttributeList;
    }
660820
public function calculateChangeSet()
    {
        if (false === $this->isDirty()) {
            return [];
        }
        return [
            'old' => empty($this->original) ? null : $this->original,
            'new' => empty($this->models) ? null : $this->models,
        ];
    }
1062871
public function getDirty()
    {
        $dirty    = [];
        $original = $this->getCastedOriginal();

        foreach ($this->attributes as $key => $value) {
            if ($this->hasCast($key, $value)) {
                $value = $this->castAttribute($key, $value);
            }

            if (
                ! array_key_exists($key, $original) ||
                ($value !== $original[$key] && ! $this->originalIsNumericallyEquivalent($key))
            ) {
                $dirty[$key] = $value;
            }
        }

        return $dirty;
    }
1057987
public function getAttributes()
    {
        if ($this->hasSourceComponent()) {
            
            $attributes = $this->SourceComponent()->getAttributes();
            
            if ($this->StyleID) {
                $attributes['id'] = $this->StyleID;
            }
            
            if ($this->StyleClasses) {
                $attributes['class'] .= sprintf(' %s', $this->StyleClasses);
            }
            
            return $attributes;
            
        }
        
        return parent::getAttributes();
    }
545574
public function getAttributes()
    {
        return [
            Attributes\IdAttribute::make(),
            Attributes\TextAttribute::make('name')
                ->setRequired(true)
                ->setUnique(true),
            Attributes\LongTextAttribute::make('description'),
            Attributes\ClassNameAttribute::make('class_name', [PriceRuleContract::class])
                ->setRequired(true),
            Attributes\ObjectAttribute::make('payload'),
            Attributes\CreatedAtAttribute::make(),
            Attributes\UpdatedAtAttribute::make(),
            Attributes\DeletedAtAttribute::make(),
        ];
    }
299519
public function getAttributes()
    {
        return [
            Attributes\IdAttribute::make(),
            Attributes\BelongsToAttribute::make('target_id')
                ->setRelationName('target')
                ->setRelationManager(TargetManager::class)
                ->setRequired(true),
            Attributes\EnumAttribute::make('targetable_type', app('amethyst')->getMorphListable('targetable', 'targetable'))
                ->setRequired(true),
            Attributes\MorphToAttribute::make('targetable_id')
                ->setRelationKey('targetable_type')
                ->setRelationName('targetable')
                ->setRelations(app('amethyst')->getMorphRelationable('targetable', 'targetable'))
                ->setRequired(true),
            Attributes\CreatedAtAttribute::make(),
            Attributes\UpdatedAtAttribute::make(),
            Attributes\DeletedAtAttribute::make(),
        ];
    }
926647
public function getWrapperAttributes()
    {
        $attributes = [
            'id' => $this->WrapperID,
            'class' => $this->WrapperClass
        ];
        
        $this->extend('updateWrapperAttributes', $attributes);
        
        $attributes = array_merge($attributes, $this->getWrapperDataAttributes());
        
        return $attributes;
    }
441221
public function getImageAttributes()
    {
        $attributes = [
            'src' => $this->ImageURL,
            'class' => $this->ImageClass,
            'title' => $this->ImageTitleText,
            'alt' => $this->ImageAltText
        ];
        
        if ($this->hasVectorImage()) {
            
            if ($width = $this->ImageResizeWidth) {
                $attributes['width'] = $width;
            }
            
            if ($height = $this->ImageResizeHeight) {
                $attributes['height'] = $height;
            }
            
        }
        
        $this->extend('updateImageAttributes', $attributes);
        
        return $attributes;
    }
731500
public function getMutatedAttributes()
    {
        $attributes = parent::getMutatedAttributes();
        $jsonAttributes = array_keys($this->jsonAttributes);

        return array_merge($attributes, $jsonAttributes);
    }
885816
protected function getModifiedData()
    {
        $modified = [];

        foreach ($this->_attributes as $key=>$value) {

            // Every previously not existing key is modified
            if (!array_key_exists($key, $this->_originalAttributes)) {
                $modified[$key] = $value;
                continue;
            }

            if ($this->valueWasModified($this->_originalAttributes[$key], $this->_attributes[$key])) {
                $modified[$key] = $value;
            }
        }

        return $modified;
    }