EMMA Coverage Report (generated Fri Aug 21 15:59:46 BST 2009)
[all classes][org.springframework.batch.core.listener]

COVERAGE SUMMARY FOR SOURCE FILE [StepListenerSupport.java]

nameclass, %method, %block, %line, %
StepListenerSupport.java100% (1/1)87%  (13/15)84%  (16/19)87%  (13/15)

COVERAGE BREAKDOWN BY CLASS AND METHOD

nameclass, %method, %block, %line, %
     
class StepListenerSupport100% (1/1)87%  (13/15)84%  (16/19)87%  (13/15)
onErrorInStep (StepExecution, Throwable): ExitStatus 0%   (0/1)0%   (0/2)0%   (0/1)
onProcessError (Object, Exception): void 0%   (0/1)0%   (0/1)0%   (0/1)
StepListenerSupport (): void 100% (1/1)100% (3/3)100% (1/1)
afterChunk (): void 100% (1/1)100% (1/1)100% (1/1)
afterProcess (Object, Object): void 100% (1/1)100% (1/1)100% (1/1)
afterRead (Object): void 100% (1/1)100% (1/1)100% (1/1)
afterStep (StepExecution): ExitStatus 100% (1/1)100% (2/2)100% (1/1)
afterWrite (List): void 100% (1/1)100% (1/1)100% (1/1)
beforeChunk (): void 100% (1/1)100% (1/1)100% (1/1)
beforeProcess (Object): void 100% (1/1)100% (1/1)100% (1/1)
beforeRead (): void 100% (1/1)100% (1/1)100% (1/1)
beforeStep (StepExecution): void 100% (1/1)100% (1/1)100% (1/1)
beforeWrite (List): void 100% (1/1)100% (1/1)100% (1/1)
onReadError (Exception): void 100% (1/1)100% (1/1)100% (1/1)
onWriteError (Exception, List): void 100% (1/1)100% (1/1)100% (1/1)

1/*
2 * Copyright 2006-2008 the original author or authors.
3 *
4 * Licensed under the Apache License, Version 2.0 (the "License");
5 * you may not use this file except in compliance with the License.
6 * You may obtain a copy of the License at
7 *
8 *      http://www.apache.org/licenses/LICENSE-2.0
9 *
10 * Unless required by applicable law or agreed to in writing, software
11 * distributed under the License is distributed on an "AS IS" BASIS,
12 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 * See the License for the specific language governing permissions and
14 * limitations under the License.
15 */
16package org.springframework.batch.core.listener;
17 
18import java.util.List;
19 
20import org.springframework.batch.core.ChunkListener;
21import org.springframework.batch.core.ExitStatus;
22import org.springframework.batch.core.ItemProcessListener;
23import org.springframework.batch.core.ItemReadListener;
24import org.springframework.batch.core.ItemWriteListener;
25import org.springframework.batch.core.StepExecution;
26import org.springframework.batch.core.StepExecutionListener;
27import org.springframework.batch.core.StepListener;
28 
29/**
30 * Basic no-op implementations of all {@link StepListener} implementations.
31 * 
32 * @author Lucas Ward
33 *
34 */
35public class StepListenerSupport<T,S> implements StepExecutionListener, ChunkListener,
36                ItemReadListener<T>, ItemProcessListener<T,S>, ItemWriteListener<S> {
37 
38        /* (non-Javadoc)
39         * @see org.springframework.batch.core.domain.StepListener#afterStep(StepExecution stepExecution)
40         */
41        public ExitStatus afterStep(StepExecution stepExecution) {
42                return null;
43        }
44 
45        /* (non-Javadoc)
46         * @see org.springframework.batch.core.domain.StepListener#beforeStep(org.springframework.batch.core.domain.StepExecution)
47         */
48        public void beforeStep(StepExecution stepExecution) {
49        }
50 
51        /* (non-Javadoc)
52         * @see org.springframework.batch.core.domain.StepListener#onErrorInStep(java.lang.Throwable)
53         */
54        public ExitStatus onErrorInStep(StepExecution stepExecution, Throwable e) {
55                return null;
56        }
57 
58        /* (non-Javadoc)
59         * @see org.springframework.batch.core.domain.ChunkListener#afterChunk()
60         */
61        public void afterChunk() {
62        }
63 
64        /* (non-Javadoc)
65         * @see org.springframework.batch.core.domain.ChunkListener#beforeChunk()
66         */
67        public void beforeChunk() {
68        }
69 
70        /* (non-Javadoc)
71         * @see org.springframework.batch.core.domain.ItemReadListener#afterRead(java.lang.Object)
72         */
73        public void afterRead(T item) {
74        }
75 
76        /* (non-Javadoc)
77         * @see org.springframework.batch.core.domain.ItemReadListener#beforeRead()
78         */
79        public void beforeRead() {
80        }
81 
82        /* (non-Javadoc)
83         * @see org.springframework.batch.core.domain.ItemReadListener#onReadError(java.lang.Exception)
84         */
85        public void onReadError(Exception ex) {
86        }
87 
88        /* (non-Javadoc)
89         * @see org.springframework.batch.core.ItemWriteListener#afterWrite(java.util.List)
90         */
91        public void afterWrite(List<? extends S> items) {
92        }
93 
94        /* (non-Javadoc)
95         * @see org.springframework.batch.core.ItemWriteListener#beforeWrite(java.util.List)
96         */
97        public void beforeWrite(List<? extends S> items) {
98        }
99 
100        /* (non-Javadoc)
101         * @see org.springframework.batch.core.ItemWriteListener#onWriteError(java.lang.Exception, java.util.List)
102         */
103        public void onWriteError(Exception exception, List<? extends S> items) {
104        }
105 
106        /* (non-Javadoc)
107         * @see org.springframework.batch.core.ItemProcessListener#afterProcess(java.lang.Object, java.lang.Object)
108         */
109        public void afterProcess(T item, S result) {
110        }
111 
112        /* (non-Javadoc)
113         * @see org.springframework.batch.core.ItemProcessListener#beforeProcess(java.lang.Object)
114         */
115        public void beforeProcess(T item) {
116        }
117 
118        /* (non-Javadoc)
119         * @see org.springframework.batch.core.ItemProcessListener#onProcessError(java.lang.Object, java.lang.Exception)
120         */
121        public void onProcessError(T item, Exception e) {
122        }
123 
124}

[all classes][org.springframework.batch.core.listener]
EMMA 2.0.5312 (C) Vladimir Roubtsov