Zend\Form\Element\Collection要素にハイドレーション戦略を追加する方法はありますか? 私は通常の方法でそれを試しました:
$hydrator = new ClassMethods();
$hydrator->addStrategy('language', new LanguageStrategy($em));
$hydrator->addStrategy('items', new UnitItemsStrategy($em));
$this->setHydrator($hydrator);
要素で:
$this->add(array(
    'type' => 'Zend\Form\Element\Collection',
    'name' => 'items',
    'options' => array(
        'label' => 'Items',
        'count' => 1,
        'should_create_template' => true,
        'allow_add' => true,
        'target_element' => array(
            'type' => 'Application\Form\UnitItemFieldset',
        ),
    ),
));
しかし、ハイドレーター戦略が呼び出されることはありません。text呼び出されるように、別の要素に再マップするだけです。したがって、要素が a であることに関係しているようZend\Form\Element\Collectionです。