Zend framework2 Zend Framework 2,InputFilter验证值数组

Zend framework2 Zend Framework 2,InputFilter验证值数组,zend-framework2,zend-inputfilter,Zend Framework2,Zend Inputfilter,我正在使用InputFilter验证我的数据,但没有Zend\Form $entities = new Input('entities'); $entities->setRequired(false); return $entities; 实体是实体的集合 我不知道如何检查实体是否为有效数组,然后检查实体的每个值是否为有效实体。如果实体为一维数组,请使用ArrayInput。如果是多维数组,即数组的集合,请使用CollectionInputFilter

我正在使用InputFilter验证我的数据,但没有Zend\Form

    $entities = new Input('entities');
    $entities->setRequired(false);
    return $entities;
实体是实体的集合

我不知道如何检查实体是否为有效数组,然后检查实体的每个值是否为有效实体。

如果实体为一维数组,请使用ArrayInput。如果是多维数组,即数组的集合,请使用CollectionInputFilter