import java.util.List;
public class ProducerConsumerBatchCreator implements BatchCreator<ProducerConsumer> {
@Override
public RecordBatch getBatch(FragmentContext context, ProducerConsumer config, List<RecordBatch> children) throws ExecutionSetupException {
return new ProducerConsumerBatch(config, context, Iterables.getOnlyElement(children));
}