package org.wamblee.support.persistence; import java.util.List; import java.util.Map; import org.dbunit.dataset.filter.ITableFilterSimple; public class CompositeJpaCustomizer implements JpaCustomizer { private List _customizers; private CompositeJpaTables _tables; public CompositeJpaCustomizer(List aCustomizers) { _customizers = aCustomizers; _tables = new CompositeJpaTables(); for (JpaCustomizer customizer: _customizers) { _tables.add(customizer.getJpaTables()); } } @Override public void customize(PersistenceUnitDescription aPersistenceUnit, Map aJpaProperties) { for (JpaCustomizer customizer: _customizers) { customizer.customize(aPersistenceUnit, aJpaProperties); } } @Override public ITableFilterSimple getJpaTables() { return _tables; } }