Returns the original value of a field.

@param string $name The field name.

@return mixed The original value of the field.

@api
543265
public function getOriginalFieldValue($name)
    {
        if ($this->isFieldModified($name)) {
            return $this->fieldsModified[$name];
        }

        if (isset($this->data['fields'][$name])) {
            return $this->data['fields'][$name];
        }

        return null;
    }
230526
public function getPropertyValue(string $name) {
		if (isset($this->values[$name])) {
			return $this->values[$name];
		}
		return null;
	}
381836
public function getValue($name)
    {
        switch ($name) {
            case 'isDirty':
                return $this->_isDirty;

            case 'isPhantom':
                return $this->_isPhantom;

            case 'wasPhantom':
                return $this->_wasPhantom;

            case 'isValid':
                return $this->_isValid;

            case 'isNew':
                return $this->_isNew;

            case 'isUpdated':
                return $this->_isUpdated;

            case 'validationErrors':
                return array_filter($this->_validationErrors);

            case 'data':
                return $this->getData();

            case 'originalValues':
                return $this->_originalValues;

            default:
            {
                // handle field
                if (static::fieldExists($name)) {
                    return $this->_getFieldValue($name);
                }
                // handle relationship
                elseif (static::isRelational()) {
                    if (static::_relationshipExists($name)) {
                        return $this->_getRelationshipValue($name);
                    }
                }
                // default Handle to ID if not caught by fieldExists
                elseif ($name == static::$handleField) {
                    return $this->ID;
                }
            }
        }
        // undefined
        return null;
    }
386762
public function getFieldByName($name)
    {
        foreach ($this->fieldList as $field) {
            if ($field->getFieldName() === $name) {
                return $field;
            }
        }

        return null;
    }
1047444
public function get($name)
    {
        return isset($this->value[$name])
            ? $this->value[$name]
            : null;
    }
1039291
public function getBoolValue($name):?bool
    {
        $value = $this->offsetGet($name);
        if (is_null($value)) {
            return null;
        }

        return (boolean)$value;
    }
1154755
public function getOriginalFieldData($field)
    {
        if (isset($this->originalData[ $field ])) {
            return $this->originalData[ $field ];
        }

        return null;
    }
941043
function Field($name)
    {
        if (!array_key_exists($name, $this->fields))
            throw new \InvalidArgumentException($name . ' is not a valid field for '. $this->name);
        
        return $this->fields[$name];
    }
831441
protected function getPropertyValue($name)
    {
        if (strpos($name, '.') !== false) {
            return $this->owner->relField($name);
        }
        
        if ($this->owner->hasMethod($name)) {
            return $this->owner->{$name}();
        }
        
        return $this->owner->{$name};
    }
1305573
public function field($name)
    {
        if (!isset($this->_fields[$name])) {
            return null;
        }

        return $this->_fields[$name];
    }
1076069
public function getForeignField($name)
    {
        $field = $this->getField($name);

        return $field instanceof ForeignField ? $field : null;
    }
121010
public function getField($name)
    {
        if ($this->has($name)) {
            return $this->fields[$name];
        }

        $this->fieldDoesNotExist($name);
    }
436811
public function get($name)
    {
        if (!array_key_exists($name, $this->_values)) {
            return null;
        }

        return $this->_values[$name];
    }
718037
public function getValue($name)
    {
        $value = null;
        if ($this->has($name)) {
            $value = call_user_func_array(
                [$this->_inputs[$name], 'getValue'],
                [$name]
            );
        }
        return $value;
    }
1100484
public function getFieldValue($name)
    {
        $fieldValues = $this->toArray();
        return (isset($fieldValues[$name])) ? $fieldValues[$name] : null;
    }
549722
public function getValue($name)
    {
        return (isset($this->options['params'][$name])) ? $this->options['params'][$name] : null;
    }
1259599
public function getRecurseAttribute($name)
    {
        $value = $this->getAttribute($name);
        $parent = $this->parent;
        if($value === null && $parent)
        {
            $value = $parent->getRecurseAttribute($name);
            $this->setAttribute($name, $value);
            return $value;
        }

        return $value;
    }