def _validate_list(self, target):
<EOL>min_items = self._field.field_definition.get('<STR_LIT>')<EOL>max_items = self._field.field_definition.get('<STR_LIT>')<EOL>if min_items is not None:<EOL><INDENT>if len(target) < min_items:<EOL><INDENT>raise ValidationError(<EOL>self._record,<EOL>"<STR_LIT>".format(self._field.name, min_items)<EOL>)<EOL><DEDENT><DEDENT>if max_items is not None:<EOL><INDENT>if len(target) > max_items:<EOL><INDENT>raise ValidationError(<EOL>self._record,<EOL>"<STR_LIT>".format(self._field.name, max_items)<EOL>)<EOL><DEDENT><DEDENT>for item in target:<EOL><INDENT>self._validate_item(item)<EOL><DEDENT>
Validate a list against field validation rules