You are here

public static function CRM_Utils_Type::validateAll in CiviCRM Entity 8.3

Helper function to call validate on arrays

See also

validate

File

tests/src/Type.php, line 186

Class

CRM_Utils_Type
@package CRM @copyright CiviCRM LLC (c) 2004-2017

Code

public static function validateAll($data, $type, $abort = TRUE) {
  foreach ($data as $key => $value) {
    $data[$key] = CRM_Utils_Type::validate($value, $type, $abort);
  }
  return $data;
}