Retrieve a list of `Invalid` errors. The returning array will
have one level deep only.

@return array<Invalid>
7853
public function getFlatErrors(): array
    {
        /**
         * Reducer that flat the errors.
         *
         * @param array   $carry previous error list
         * @param Invalid $item  to append to $carry
         *
         * @return array<Invalid>
         */
        $reduce = function(array $carry, Invalid $item) use(&$reduce) {
            if ($item instanceof self) {
                $carry = array_merge($carry, $item->getFlatErrors());
            } else {
                $carry[] = $item;
            }
            if ($item->getPrevious()) {
                $carry = $reduce($carry, $item->getPrevious());
            }

            return $carry;
        };

        return array_reduce($this->errors, $reduce, []);
    }
576574
public function getFailures(): array
    {
        $errors = [];

        foreach ($this->getActionExceptions() as $actionException) {
            $errors[] = $actionException->getMessage();
        }

        return $errors;
    }
896340
public function getErrorLists()
    {
        $names = array_values($this->action_names);
        $errors = [];
        foreach ($names as $name) {
            $errors[$name] = $this->getErrorListByName($name);
        }
        return $errors;
    }
978540
function valid_errors(errors) {

  /**
   *  Return false if [errors] is empty or if it isn't a non-empty array.
   */

  if (! errors) {
    return false;
  } else {
    if (! (errors instanceof Array)) {
      return false;
    } else {
      if (errors.length === 0) {
        return false;
      }
    }
  }

  return true;

}
1374721
public function getErrors() {
        $result = array();

        if (count($this->errors) > 0) {
            if (isset($this->errors['common'])) {
                $result['common'] = $this->errors['common'];
            }
            if (isset($this->errors['fields'])) {
                foreach ($this->errors['fields'] as $key => $value) {
                    $result[$key] = $value;
                }
            }
        }
        
        return $result;
    }
544993
public function getErrors()
    {
        if (false === $this->errors) {
            $this->errors = array();
        }

        if (!is_array($this->errors)) {
            $this->errors = array($this->errors);
        }

        return $this->errors;
    }
205625
public function getInvalidAttribs()
    {
        return array_combine(
            array_keys($this->invalidAttribs),
            array_map(function ($ref) {
                return $ref['attrib'];
            }, array_values($this->invalidAttribs))
        );
    }
154458
@com.fasterxml.jackson.annotation.JsonProperty("validationErrors")
    public java.util.List<ValidationError> getValidationErrors() {
        return validationErrors;
    }
17969
public Invalidation[] getInvalidations(){
		Invalidation[] invalidations = new Invalidation[configEntry.invalidations.length];
		for ( int i=0; i<configEntry.invalidations.length; i++ ){
			invalidations[i] = new Invalidation(configEntry.invalidations[i]);
		}
		return invalidations;
	}
721969
public function getInvalidReleases()
    {
        $releases = $this->getReleases();
        $invalid = array_diff($this->state, array_filter($this->state));
        $invalid = array_keys($invalid);

        return array_intersect($releases, $invalid);
    }
1134450
public function getErrorMessages() : array
    {
        $errors = $this->getErrors(true);
        $return = array();
        foreach ($errors as $error) {
            $return[] = 'Field: ' . $error->getFieldName() . '| Message: ' . $error->getErrorMessage();
        }
        return $return;
    }
35578
function(errors) {
      var ret = [];
      errors.forEach(function(error) {
        // Removes errors without a message
        if (v.isArray(error.error)) {
          error.error.forEach(function(msg) {
            ret.push(v.extend({}, error, {error: msg}));
          });
        } else {
          ret.push(error);
        }
      });
      return ret;
    }
388826
public function getErrors()
    {
        if ($this->errors === null) {
            if ($errors = $this['errors']) {
                foreach ($errors as $key => $error) {
                    $errors[$key] = $this->shapeFor($error);
                }
                $this->errors = $errors;
            } else {
                $this->errors = [];
            }
        }

        return $this->errors;
    }
339945
public function getErrors() {
		if ($this->forbiddenClasses) {
			return $this->forbiddenClasses;
		}
		
		if ($this->useCache) {
			// Cache duration: 30 minutes.
			$this->forbiddenClasses = $this->cacheService->get("forbidden.classes.".__DIR__."/".json_encode($this->selfEdit));
			if ($this->forbiddenClasses != null) {
				return $this->forbiddenClasses;
			}
		}
		
		$this->analyze();
		return $this->forbiddenClasses;
	}
722514
public function getValidationErrors()
    {
        if ($this->isValid()) {
            return [];
        }
        
        // if it's already cached, just return it
        if (count($this->validationErrors) > 0) {
            return $this->validationErrors;
        }


        // All errors can be spotted in the fields
        foreach ($this->getFields() as $field) {
            if (!$field->isValid()) {
                $this->validationErrors[$field->getName()] = $field->getErrors(true);
            }
        }

        return $this->validationErrors;
    }
969955
public static InvalidKBException validationErrors(List<String> errors){
        StringBuilder message = new StringBuilder();
        message.append(ErrorMessage.VALIDATION.getMessage(errors.size()));
        for (String s : errors) {
            message.append(s);
        }
        return create(message.toString());
    }
1040173
public List<Throwable> getErrors() {
        List<Throwable> list = new ArrayList<>();
        list.addAll(errors);
        for (PathWrapper ar : pathWrappers) {
            list.addAll(ar.getErrors());
        }
        return list;
    }