Method to check a field exists.

@param string $field The field name to check.

@return  boolean True if exists.
10866
public function exists($field)
    {
        // Remove \0 from begin of field name.
        if (strpos($field, "\0") === 0) {
            $field = substr($field, 3);
        }

        return isset($this->$field);
    }
1028741
public function createCustomField(Field $field)
		{
			$form_data = array(
				'fieldname' => $field->getName(),
				'fieldtype' => $field->getType(),
				'description' => $field->getDescription()
			);
			$this->call('customfieldcreate', $form_data);

			return TRUE;
		}
1262743
public function getValue($field)
  {
    $v = $this->getValues();

    return isset($v[$field]) ? $v[$field] : false;
  }
1362144
public function valueExists($field, $value = null)
    {
        $record = new static($this->table, $this->keys, $this->mapper);

        if ($value === null) {
            $value = $this->$field;
        }

        try {
            $record->load([$field => $value]);
        } catch (NoResultException $e) {
            return false;
        }

        if ($record->$field != $value) {
            return false;
        }

        // check record keys same as self
        $same = [];

        foreach ($this->keys as $key) {
            $same[] = ($record->$key == $this->$key);
        }

        // Key not same, means same value exists in other record.
        if (in_array(false, $same, true)) {
            return true;
        }

        return false;
    }
487957
public function isFieldVirtualised($field)
    {
        // Don't defer if field is non-virtualised
        $ignore = $this->getNonVirtualisedFields();
        if (in_array($field, $ignore)) {
            return false;
        }

        // Don't defer if no virtual page
        $copied = $this->CopyContentFrom();
        if (!$copied || !$copied->exists()) {
            return false;
        }

        // Check if copied object has this field
        return $copied->hasField($field);
    }
154265
public function isRequired($field)
    {
        $parts = explode('.', $field);
        $entity = $this->entity($parts);

        $isNew = true;
        if ($entity instanceof EntityInterface) {
            $isNew = $entity->isNew();
        }

        $validator = $this->_getValidator($parts);
        $fieldName = array_pop($parts);
        if (!$validator->hasField($fieldName)) {
            return false;
        }
        if ($this->type($field) !== 'boolean') {
            return $validator->isEmptyAllowed($fieldName, $isNew) === false;
        }

        return false;
    }
562226
protected function getField($field)
    {
        if ($this->isFieldSupported($field) && isset($this->fields[ $field ])) {
            return $this->fields[ $field ];
        }

        return null;
    }
725257
public function offsetExists($field) {
        return isset($this->values[$field]) || isset($this->factories[$field]);
    }
1152997
private function hasFields($fields)
    {
        $hasFields = true;
        
        foreach ($fields as $field_name)
        {
            if (!isset($this->m_fields[$field_name]))
            {
                $dbgMsg = 'Hasfields returning that ' . $field_name . ' does ' .
                          'not exist in ' . print_r($this->m_fields, true);
                
                LogModel::debugLog($dbgMsg);
                $hasFields = false;
                break;
            }
        }
        
        return $hasFields;
    }
1292600
public function hasFieldError($field)
    {
        foreach ((array)$this->errors as $err) {

            if ($err instanceof FieldValidationError) {
                $tfield = $err->getFieldResolved();
                if($tfield == $field)
                    return true;
            }
        }

        return false;
    }
451257
public function iShouldNotSeeTheField($field) {
    $element = $this->getSession()->getPage();
    $this->assertElementNotVisible($field, $element->findField($field));
  }
346285
public function HasField ($fieldOrFieldName = NULL) {
		$fieldName = NULL;
		if ($fieldOrFieldName instanceof \MvcCore\Ext\Forms\IField) {
			$fieldName = $fieldOrFieldName->GetName();
		} else if (is_string($fieldOrFieldName)) {
			$fieldName = $fieldOrFieldName;
		}
		return isset($this->fields[$fieldName]);
	}
1234039
def field_name_exist(self, field_name):
        

        fields = self.class_item.get_fields()
        for f in fields:
            if f.name == field_name:
                return True
        return False
522773
protected function isExcluded($field)
    {
        return isset($this->options['field']) && $this->options['field'] !== $this->getKey($field);
    }
538381
public function isFieldExists($table, $field)
	{
		if (isset($this->tables[$table])) {
			$fields = $this->getFields($table);

			return $fields->where('name', $field)->count() > 0;
		}

		return false;
	}
853401
public function has( $key ) {
		return isset( $this->fields[$key] ) || array_key_exists( $key, $this->fields );
	}
1182614
private function hasUploadField($field, $definedField)
    {
        // check for string key
        if (array_has($definedField, $field)) {
            return true;
        }

        // check for value
        $found = false;
        foreach ($definedField as $key => $val) {
            $found = (is_numeric($key) && $val === $field);

            if ($found) {
                break;
            }
        }

        return $found;
    }