public List<ItemWriteListenerProxy> getItemWriteListeners(Step step, InjectionReferences injectionRefs, StepContextImpl stepContext) { List<ListenerInfo> stepListenerInfo = getStepListenerInfo(step, injectionRefs); List<ItemWriteListenerProxy> retVal = new ArrayList<ItemWriteListenerProxy>(); for (ListenerInfo li : stepListenerInfo) { if (li.isItemWriteListener()) { ItemWriteListenerProxy proxy = new ItemWriteListenerProxy((ItemWriteListener) li.getArtifact()); proxy.setStepContext(stepContext); retVal.add(proxy); } } return retVal; }
writeListenerProxy.beforeWrite(theChunk); writeListenerProxy.afterWrite(theChunk); writeListenerProxy.onWriteError(theChunk, e);
writeListenerProxy.beforeWrite(theChunk); writeListenerProxy.afterWrite(theChunk); writeListenerProxy.onWriteError(theChunk, e);
writeListenerProxy.beforeWrite(theChunk); writeListenerProxy.afterWrite(theChunk); this.stepContext.setException(e); for (ItemWriteListenerProxy writeListenerProxy : itemWriteListeners) { writeListenerProxy.onWriteError(theChunk, e);
public List<ItemWriteListenerProxy> getItemWriteListeners(Step step, InjectionReferences injectionRefs, RuntimeStepExecution stepContext) { List<ListenerInfo> stepListenerInfo = getStepListenerInfo(step, injectionRefs); List<ItemWriteListenerProxy> retVal = new ArrayList<ItemWriteListenerProxy>(); for (ListenerInfo li : stepListenerInfo) { if (li.isItemWriteListener()) { ItemWriteListenerProxy proxy = new ItemWriteListenerProxy((ItemWriteListener) li.getArtifact()); proxy.setStepContext(stepContext); retVal.add(proxy); } } return retVal; }
public List<ItemWriteListenerProxy> getItemWriteListeners(Step step, InjectionReferences injectionRefs, StepContextImpl stepContext) { List<ListenerInfo> stepListenerInfo = getStepListenerInfo(step, injectionRefs); List<ItemWriteListenerProxy> retVal = new ArrayList<ItemWriteListenerProxy>(); for (ListenerInfo li : stepListenerInfo) { if (li.isItemWriteListener()) { ItemWriteListenerProxy proxy = new ItemWriteListenerProxy((ItemWriteListener) li.getArtifact()); proxy.setStepContext(stepContext); retVal.add(proxy); } } return retVal; }