processors = $processors; } /** * Retrieve all LineItemProcessors * * @return OrderProcessorInterface[] */ public function getProcessors() { return $this->processors; } /** * Use a pool of OrderProcessors to update the Invoice Request * * @param RequestInterface $request * @param OrderInterface $order * @return RequestInterface */ public function process(RequestInterface $request, OrderInterface $order) { foreach ($this->getProcessors() as $processor) { $request = $processor->process($request, $order); } return $request; } }