diff --git a/spring-batch-execution/src/main/java/org/springframework/batch/execution/step/support/ItemSkipPolicyItemHandler.java b/spring-batch-execution/src/main/java/org/springframework/batch/execution/step/support/ItemSkipPolicyItemHandler.java index 526211869..f0a82c050 100644 --- a/spring-batch-execution/src/main/java/org/springframework/batch/execution/step/support/ItemSkipPolicyItemHandler.java +++ b/spring-batch-execution/src/main/java/org/springframework/batch/execution/step/support/ItemSkipPolicyItemHandler.java @@ -17,9 +17,9 @@ package org.springframework.batch.execution.step.support; import org.springframework.batch.core.ItemSkipPolicy; import org.springframework.batch.core.StepContribution; -import org.springframework.batch.io.Skippable; import org.springframework.batch.item.ItemReader; import org.springframework.batch.item.ItemWriter; +import org.springframework.batch.item.Skippable; import org.springframework.batch.repeat.ExitStatus; /** @@ -88,7 +88,7 @@ public class ItemSkipPolicyItemHandler extends SimpleItemHandler { * Mark the current item as skipped if possible. If the reader and / or * writer are {@link Skippable} then delegate to them in that order. * - * @see org.springframework.batch.io.Skippable#skip() + * @see org.springframework.batch.item.Skippable#skip() */ private void skip() { if (getItemReader() instanceof Skippable) { diff --git a/spring-batch-execution/src/test/java/org/springframework/batch/execution/job/SimpleJobTests.java b/spring-batch-execution/src/test/java/org/springframework/batch/execution/job/SimpleJobTests.java index 49ca09db2..cd5532db9 100644 --- a/spring-batch-execution/src/test/java/org/springframework/batch/execution/job/SimpleJobTests.java +++ b/spring-batch-execution/src/test/java/org/springframework/batch/execution/job/SimpleJobTests.java @@ -42,9 +42,9 @@ import org.springframework.batch.execution.repository.dao.StepExecutionDao; import org.springframework.batch.execution.step.AbstractStep; import org.springframework.batch.execution.step.support.NeverSkipItemSkipPolicy; import org.springframework.batch.io.exception.InfrastructureException; +import org.springframework.batch.item.AbstractItemReader; import org.springframework.batch.item.ItemReader; import org.springframework.batch.item.ItemWriter; -import org.springframework.batch.item.reader.AbstractItemReader; import org.springframework.batch.repeat.ExitStatus; import org.springframework.batch.repeat.exception.handler.ExceptionHandler; import org.springframework.batch.retry.RetryPolicy; diff --git a/spring-batch-execution/src/test/java/org/springframework/batch/execution/step/ItemOrientedStepTests.java b/spring-batch-execution/src/test/java/org/springframework/batch/execution/step/ItemOrientedStepTests.java index 9277c1ecc..f1602fe3e 100644 --- a/spring-batch-execution/src/test/java/org/springframework/batch/execution/step/ItemOrientedStepTests.java +++ b/spring-batch-execution/src/test/java/org/springframework/batch/execution/step/ItemOrientedStepTests.java @@ -40,17 +40,17 @@ import org.springframework.batch.execution.step.support.JobRepositorySupport; import org.springframework.batch.execution.step.support.SimpleItemHandler; import org.springframework.batch.execution.step.support.StepInterruptionPolicy; import org.springframework.batch.io.exception.InfrastructureException; +import org.springframework.batch.item.AbstractItemReader; +import org.springframework.batch.item.AbstractItemWriter; import org.springframework.batch.item.ExecutionContext; import org.springframework.batch.item.ItemReader; import org.springframework.batch.item.ItemStream; +import org.springframework.batch.item.ItemStreamSupport; import org.springframework.batch.item.ItemWriter; import org.springframework.batch.item.MarkFailedException; import org.springframework.batch.item.ResetFailedException; import org.springframework.batch.item.ItemStreamException; -import org.springframework.batch.item.reader.AbstractItemReader; import org.springframework.batch.item.reader.ListItemReader; -import org.springframework.batch.item.stream.ItemStreamSupport; -import org.springframework.batch.item.writer.AbstractItemWriter; import org.springframework.batch.repeat.ExitStatus; import org.springframework.batch.repeat.RepeatContext; import org.springframework.batch.repeat.policy.SimpleCompletionPolicy; diff --git a/spring-batch-execution/src/test/java/org/springframework/batch/execution/step/support/DefaultStepFactoryBeanTests.java b/spring-batch-execution/src/test/java/org/springframework/batch/execution/step/support/DefaultStepFactoryBeanTests.java index 2f5f13a71..8020023fe 100644 --- a/spring-batch-execution/src/test/java/org/springframework/batch/execution/step/support/DefaultStepFactoryBeanTests.java +++ b/spring-batch-execution/src/test/java/org/springframework/batch/execution/step/support/DefaultStepFactoryBeanTests.java @@ -35,10 +35,10 @@ import org.springframework.batch.execution.repository.dao.MapJobInstanceDao; import org.springframework.batch.execution.repository.dao.MapStepExecutionDao; import org.springframework.batch.execution.step.AbstractStep; import org.springframework.batch.execution.step.ItemOrientedStep; +import org.springframework.batch.item.AbstractItemWriter; import org.springframework.batch.item.ItemReader; import org.springframework.batch.item.ItemWriter; import org.springframework.batch.item.reader.ListItemReader; -import org.springframework.batch.item.writer.AbstractItemWriter; import org.springframework.batch.repeat.RepeatContext; import org.springframework.batch.repeat.exception.handler.ExceptionHandler; import org.springframework.batch.repeat.support.RepeatTemplate; diff --git a/spring-batch-execution/src/test/java/org/springframework/batch/execution/step/support/StatefulRetryStepFactoryBeanTests.java b/spring-batch-execution/src/test/java/org/springframework/batch/execution/step/support/StatefulRetryStepFactoryBeanTests.java index 2484a341b..c445c0a60 100644 --- a/spring-batch-execution/src/test/java/org/springframework/batch/execution/step/support/StatefulRetryStepFactoryBeanTests.java +++ b/spring-batch-execution/src/test/java/org/springframework/batch/execution/step/support/StatefulRetryStepFactoryBeanTests.java @@ -33,11 +33,11 @@ import org.springframework.batch.execution.repository.dao.MapJobExecutionDao; import org.springframework.batch.execution.repository.dao.MapJobInstanceDao; import org.springframework.batch.execution.repository.dao.MapStepExecutionDao; import org.springframework.batch.execution.step.ItemOrientedStep; +import org.springframework.batch.item.AbstractItemWriter; import org.springframework.batch.item.ItemReader; import org.springframework.batch.item.ItemRecoverer; import org.springframework.batch.item.ItemWriter; import org.springframework.batch.item.reader.ListItemReader; -import org.springframework.batch.item.writer.AbstractItemWriter; import org.springframework.batch.support.transaction.ResourcelessTransactionManager; import org.springframework.batch.support.transaction.TransactionAwareProxyFactory; import org.springframework.transaction.support.TransactionSynchronizationManager; diff --git a/spring-batch-execution/src/test/java/org/springframework/batch/execution/step/support/StepExecutorInterruptionTests.java b/spring-batch-execution/src/test/java/org/springframework/batch/execution/step/support/StepExecutorInterruptionTests.java index 75a1b4f6a..950fcc140 100644 --- a/spring-batch-execution/src/test/java/org/springframework/batch/execution/step/support/StepExecutorInterruptionTests.java +++ b/spring-batch-execution/src/test/java/org/springframework/batch/execution/step/support/StepExecutorInterruptionTests.java @@ -30,8 +30,8 @@ import org.springframework.batch.execution.repository.dao.MapJobExecutionDao; import org.springframework.batch.execution.repository.dao.MapJobInstanceDao; import org.springframework.batch.execution.repository.dao.MapStepExecutionDao; import org.springframework.batch.execution.step.ItemOrientedStep; -import org.springframework.batch.item.reader.AbstractItemReader; -import org.springframework.batch.item.writer.AbstractItemWriter; +import org.springframework.batch.item.AbstractItemReader; +import org.springframework.batch.item.AbstractItemWriter; import org.springframework.batch.repeat.policy.SimpleCompletionPolicy; import org.springframework.batch.repeat.support.RepeatTemplate; import org.springframework.batch.support.transaction.ResourcelessTransactionManager; diff --git a/spring-batch-infrastructure/.springBeans b/spring-batch-infrastructure/.springBeans index 826912ba0..63d1f8c14 100644 --- a/spring-batch-infrastructure/.springBeans +++ b/spring-batch-infrastructure/.springBeans @@ -1,14 +1,18 @@ 1 - + - src/test/resources/org/springframework/batch/io/sql/data-source-context.xml src/test/resources/org/springframework/batch/retry/aop/retry-transaction-test.xml + src/test/resources/org/springframework/batch/item/database/data-source-context.xml + src/test/resources/org/springframework/batch/item/file/mapping/bean-wrapper.xml + src/test/resources/org/springframework/batch/item/reader/delegating-item-provider.xml + src/test/resources/org/springframework/batch/item/writer/delegating-item-writer.xml + src/test/resources/org/springframework/batch/item/writer/pe-delegating-item-writer.xml diff --git a/spring-batch-infrastructure/src/main/java/org/springframework/batch/io/cursor/package.html b/spring-batch-infrastructure/src/main/java/org/springframework/batch/io/cursor/package.html deleted file mode 100644 index c85e3934e..000000000 --- a/spring-batch-infrastructure/src/main/java/org/springframework/batch/io/cursor/package.html +++ /dev/null @@ -1,8 +0,0 @@ - - -

-Infrastructure implementations of cursor based input sources. All input sources within this package -open a cursor against the database, and return back a mapped object for each row. -

- - diff --git a/spring-batch-infrastructure/src/main/java/org/springframework/batch/io/driving/package.html b/spring-batch-infrastructure/src/main/java/org/springframework/batch/io/driving/package.html deleted file mode 100644 index f5be70a91..000000000 --- a/spring-batch-infrastructure/src/main/java/org/springframework/batch/io/driving/package.html +++ /dev/null @@ -1,8 +0,0 @@ - - -

-Infrastructure implementations of driving query based input sources. All input sources within this package -query a database to return a list of keys, and return back one key per call to read(). -

- - diff --git a/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/reader/AbstractItemReader.java b/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/AbstractItemReader.java similarity index 80% rename from spring-batch-infrastructure/src/main/java/org/springframework/batch/item/reader/AbstractItemReader.java rename to spring-batch-infrastructure/src/main/java/org/springframework/batch/item/AbstractItemReader.java index 241b15b6d..a005b7427 100644 --- a/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/reader/AbstractItemReader.java +++ b/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/AbstractItemReader.java @@ -14,11 +14,8 @@ * limitations under the License. */ -package org.springframework.batch.item.reader; +package org.springframework.batch.item; -import org.springframework.batch.item.ItemReader; -import org.springframework.batch.item.MarkFailedException; -import org.springframework.batch.item.ResetFailedException; /** * Base class for {@link ItemReader} implementations. diff --git a/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/reader/AbstractItemStreamItemReader.java b/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/AbstractItemStreamItemReader.java similarity index 83% rename from spring-batch-infrastructure/src/main/java/org/springframework/batch/item/reader/AbstractItemStreamItemReader.java rename to spring-batch-infrastructure/src/main/java/org/springframework/batch/item/AbstractItemStreamItemReader.java index 4f96e02d1..abcc719cb 100644 --- a/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/reader/AbstractItemStreamItemReader.java +++ b/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/AbstractItemStreamItemReader.java @@ -14,10 +14,8 @@ * limitations under the License. */ -package org.springframework.batch.item.reader; +package org.springframework.batch.item; -import org.springframework.batch.item.ItemReader; -import org.springframework.batch.item.stream.ItemStreamSupport; /** * Base class for {@link ItemReader} implementations. diff --git a/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/writer/AbstractItemStreamItemWriter.java b/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/AbstractItemStreamItemWriter.java similarity index 83% rename from spring-batch-infrastructure/src/main/java/org/springframework/batch/item/writer/AbstractItemStreamItemWriter.java rename to spring-batch-infrastructure/src/main/java/org/springframework/batch/item/AbstractItemStreamItemWriter.java index 6696932e1..feeaf4a31 100644 --- a/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/writer/AbstractItemStreamItemWriter.java +++ b/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/AbstractItemStreamItemWriter.java @@ -14,10 +14,8 @@ * limitations under the License. */ -package org.springframework.batch.item.writer; +package org.springframework.batch.item; -import org.springframework.batch.item.ItemWriter; -import org.springframework.batch.item.stream.ItemStreamSupport; /** * Base class for {@link ItemWriter} implementations. diff --git a/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/writer/AbstractItemWriter.java b/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/AbstractItemWriter.java similarity index 83% rename from spring-batch-infrastructure/src/main/java/org/springframework/batch/item/writer/AbstractItemWriter.java rename to spring-batch-infrastructure/src/main/java/org/springframework/batch/item/AbstractItemWriter.java index 601b00521..b40e37915 100644 --- a/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/writer/AbstractItemWriter.java +++ b/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/AbstractItemWriter.java @@ -13,11 +13,8 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package org.springframework.batch.item.writer; +package org.springframework.batch.item; -import org.springframework.batch.item.ClearFailedException; -import org.springframework.batch.item.FlushFailedException; -import org.springframework.batch.item.ItemWriter; /** * Abstract {@link ItemWriter} that allows for base classes to only diff --git a/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/ItemReader.java b/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/ItemReader.java index 5db7d4557..fe36b123b 100644 --- a/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/ItemReader.java +++ b/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/ItemReader.java @@ -16,22 +16,16 @@ package org.springframework.batch.item; -import org.springframework.batch.item.reader.AbstractItemReader; - /** * Strategy interface for providing the data.
* - * Implementations are expected to be stateful and will be called multiple times - * for each batch, with each call to {@link #next} returning a different value - * and finally returning null when all input data is exhausted.
+ * Implementations are expected to be stateful and will be called multiple times for each batch, with each call to + * {@link #next} returning a different value and finally returning null when all input data is exhausted.
* - * Implementations need to be thread safe and clients of a {@link ItemReader} - * need to be aware that this is the case. Clients can code to this interface - * without worrying about thread safety by using the {@link AbstractItemReader} - * base class.
+ * Implementations need to be thread safe and clients of a {@link ItemReader} need to be aware that this is the case.
* - * A richer interface (e.g. with a look ahead or peek) is not feasible because - * we need to support transactions in an asynchronous batch. + * A richer interface (e.g. with a look ahead or peek) is not feasible because we need to support transactions in an + * asynchronous batch. * * @author Rob Harrop * @author Dave Syer @@ -41,11 +35,9 @@ import org.springframework.batch.item.reader.AbstractItemReader; public interface ItemReader { /** - * Reads a piece of input data and advance to the next one. Implementations - * must return null at the end of the input - * data set. In a transactional setting, caller might get the same item - * twice from successive calls (or otherwise), if the first call was in a - * transaction that rolled back. + * Reads a piece of input data and advance to the next one. Implementations must return + * null at the end of the input data set. In a transactional setting, caller might get the same item + * twice from successive calls (or otherwise), if the first call was in a transaction that rolled back. * * @throws Exception if an underlying resource is unavailable. */ @@ -54,27 +46,22 @@ public interface ItemReader { /** * Mark the stream so that it can be reset later and the items backed out.
* - * In a multi-threaded setting implementations have to ensure that only the - * state from the current thread is saved. + * In a multi-threaded setting implementations have to ensure that only the state from the current thread is saved. * - * @throws MarkFailedException if there is a problem with the mark. If a - * mark fails inside a transaction, it would be worrying, but not normally - * fatal. + * @throws MarkFailedException if there is a problem with the mark. If a mark fails inside a transaction, it would + * be worrying, but not normally fatal. */ void mark() throws MarkFailedException; /** - * Reset the stream to the last mark. After a reset the stream state will be - * such that changes (items read or written) since the last call to mark - * will not be visible after a call to close.
+ * Reset the stream to the last mark. After a reset the stream state will be such that changes (items read or + * written) since the last call to mark will not be visible after a call to close.
* - * In a multi-threaded setting implementations have to ensure that only the - * state from the current thread is reset. + * In a multi-threaded setting implementations have to ensure that only the state from the current thread is reset. * - * @throws ResetFailedException if there is a problem with the reset. If a - * reset fails inside a transaction, it would normally be fatal, and would - * leave the stream in an inconsistent state. So while this is an unchecked - * exception, it may be important for a client to catch it explicitly. + * @throws ResetFailedException if there is a problem with the reset. If a reset fails inside a transaction, it + * would normally be fatal, and would leave the stream in an inconsistent state. So while this is an + * unchecked exception, it may be important for a client to catch it explicitly. */ void reset() throws ResetFailedException; diff --git a/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/stream/ItemStreamSupport.java b/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/ItemStreamSupport.java similarity index 82% rename from spring-batch-infrastructure/src/main/java/org/springframework/batch/item/stream/ItemStreamSupport.java rename to spring-batch-infrastructure/src/main/java/org/springframework/batch/item/ItemStreamSupport.java index 5eb908c7d..00a6938ab 100644 --- a/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/stream/ItemStreamSupport.java +++ b/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/ItemStreamSupport.java @@ -13,11 +13,8 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package org.springframework.batch.item.stream; +package org.springframework.batch.item; -import org.springframework.batch.item.ExecutionContext; -import org.springframework.batch.item.ItemStream; -import org.springframework.batch.item.ItemStreamException; /** * Empty method implementation of {@link ItemStream}. @@ -25,7 +22,7 @@ import org.springframework.batch.item.ItemStreamException; * @author Dave Syer * */ -public class ItemStreamSupport implements ItemStream { +public abstract class ItemStreamSupport implements ItemStream { /** * No-op. diff --git a/spring-batch-infrastructure/src/main/java/org/springframework/batch/io/Skippable.java b/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/Skippable.java similarity index 96% rename from spring-batch-infrastructure/src/main/java/org/springframework/batch/io/Skippable.java rename to spring-batch-infrastructure/src/main/java/org/springframework/batch/item/Skippable.java index fd8070fc6..23ab4d760 100644 --- a/spring-batch-infrastructure/src/main/java/org/springframework/batch/io/Skippable.java +++ b/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/Skippable.java @@ -14,7 +14,7 @@ * limitations under the License. */ -package org.springframework.batch.io; +package org.springframework.batch.item; /** * Implementation of this interface indicates to the framework that this object diff --git a/spring-batch-infrastructure/src/main/java/org/springframework/batch/io/support/BatchSqlUpdateItemWriter.java b/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/database/BatchSqlUpdateItemWriter.java similarity index 99% rename from spring-batch-infrastructure/src/main/java/org/springframework/batch/io/support/BatchSqlUpdateItemWriter.java rename to spring-batch-infrastructure/src/main/java/org/springframework/batch/item/database/BatchSqlUpdateItemWriter.java index 698621e15..7df9c0e53 100644 --- a/spring-batch-infrastructure/src/main/java/org/springframework/batch/io/support/BatchSqlUpdateItemWriter.java +++ b/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/database/BatchSqlUpdateItemWriter.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package org.springframework.batch.io.support; +package org.springframework.batch.item.database; import java.sql.PreparedStatement; import java.sql.SQLException; diff --git a/spring-batch-infrastructure/src/main/java/org/springframework/batch/io/driving/DrivingQueryItemReader.java b/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/database/DrivingQueryItemReader.java similarity index 99% rename from spring-batch-infrastructure/src/main/java/org/springframework/batch/io/driving/DrivingQueryItemReader.java rename to spring-batch-infrastructure/src/main/java/org/springframework/batch/item/database/DrivingQueryItemReader.java index dedf1f6f2..cdbe3092d 100644 --- a/spring-batch-infrastructure/src/main/java/org/springframework/batch/io/driving/DrivingQueryItemReader.java +++ b/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/database/DrivingQueryItemReader.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package org.springframework.batch.io.driving; +package org.springframework.batch.item.database; import java.util.Iterator; import java.util.List; diff --git a/spring-batch-infrastructure/src/main/java/org/springframework/batch/io/support/HibernateAwareItemWriter.java b/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/database/HibernateAwareItemWriter.java similarity index 99% rename from spring-batch-infrastructure/src/main/java/org/springframework/batch/io/support/HibernateAwareItemWriter.java rename to spring-batch-infrastructure/src/main/java/org/springframework/batch/item/database/HibernateAwareItemWriter.java index 8fce25d47..0f8c38f8e 100644 --- a/spring-batch-infrastructure/src/main/java/org/springframework/batch/io/support/HibernateAwareItemWriter.java +++ b/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/database/HibernateAwareItemWriter.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package org.springframework.batch.io.support; +package org.springframework.batch.item.database; import java.util.HashSet; import java.util.Set; diff --git a/spring-batch-infrastructure/src/main/java/org/springframework/batch/io/cursor/HibernateCursorItemReader.java b/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/database/HibernateCursorItemReader.java similarity index 98% rename from spring-batch-infrastructure/src/main/java/org/springframework/batch/io/cursor/HibernateCursorItemReader.java rename to spring-batch-infrastructure/src/main/java/org/springframework/batch/item/database/HibernateCursorItemReader.java index c95a69e3b..572120006 100644 --- a/spring-batch-infrastructure/src/main/java/org/springframework/batch/io/cursor/HibernateCursorItemReader.java +++ b/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/database/HibernateCursorItemReader.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package org.springframework.batch.io.cursor; +package org.springframework.batch.item.database; import java.util.ArrayList; import java.util.List; @@ -22,11 +22,11 @@ import org.hibernate.ScrollableResults; import org.hibernate.Session; import org.hibernate.SessionFactory; import org.hibernate.StatelessSession; -import org.springframework.batch.io.Skippable; import org.springframework.batch.item.ExecutionContext; import org.springframework.batch.item.ExecutionContextUserSupport; import org.springframework.batch.item.ItemReader; import org.springframework.batch.item.ItemStream; +import org.springframework.batch.item.Skippable; import org.springframework.beans.factory.InitializingBean; import org.springframework.util.Assert; import org.springframework.util.StringUtils; diff --git a/spring-batch-infrastructure/src/main/java/org/springframework/batch/io/driving/IbatisDrivingQueryItemReader.java b/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/database/IbatisDrivingQueryItemReader.java similarity index 90% rename from spring-batch-infrastructure/src/main/java/org/springframework/batch/io/driving/IbatisDrivingQueryItemReader.java rename to spring-batch-infrastructure/src/main/java/org/springframework/batch/item/database/IbatisDrivingQueryItemReader.java index 7e761caed..f093543aa 100644 --- a/spring-batch-infrastructure/src/main/java/org/springframework/batch/io/driving/IbatisDrivingQueryItemReader.java +++ b/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/database/IbatisDrivingQueryItemReader.java @@ -13,9 +13,9 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package org.springframework.batch.io.driving; +package org.springframework.batch.item.database; -import org.springframework.batch.io.driving.support.IbatisKeyGenerator; +import org.springframework.batch.item.database.support.IbatisKeyGenerator; import org.springframework.orm.ibatis.SqlMapClientTemplate; import com.ibatis.sqlmap.client.SqlMapClient; @@ -36,7 +36,7 @@ public class IbatisDrivingQueryItemReader extends DrivingQueryItemReader { /** * Overridden read() that uses the returned key as arguments to the details query. * - * @see org.springframework.batch.io.driving.DrivingQueryItemReader#read() + * @see org.springframework.batch.item.database.DrivingQueryItemReader#read() */ public Object read() { Object key = super.read(); diff --git a/spring-batch-infrastructure/src/main/java/org/springframework/batch/io/support/ItemPreparedStatementSetter.java b/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/database/ItemPreparedStatementSetter.java similarity index 96% rename from spring-batch-infrastructure/src/main/java/org/springframework/batch/io/support/ItemPreparedStatementSetter.java rename to spring-batch-infrastructure/src/main/java/org/springframework/batch/item/database/ItemPreparedStatementSetter.java index 46ec69e01..4312b71eb 100644 --- a/spring-batch-infrastructure/src/main/java/org/springframework/batch/io/support/ItemPreparedStatementSetter.java +++ b/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/database/ItemPreparedStatementSetter.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package org.springframework.batch.io.support; +package org.springframework.batch.item.database; import java.sql.PreparedStatement; import java.sql.SQLException; diff --git a/spring-batch-infrastructure/src/main/java/org/springframework/batch/io/cursor/JdbcCursorItemReader.java b/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/database/JdbcCursorItemReader.java similarity index 99% rename from spring-batch-infrastructure/src/main/java/org/springframework/batch/io/cursor/JdbcCursorItemReader.java rename to spring-batch-infrastructure/src/main/java/org/springframework/batch/item/database/JdbcCursorItemReader.java index 686200609..877c05f2b 100644 --- a/spring-batch-infrastructure/src/main/java/org/springframework/batch/io/cursor/JdbcCursorItemReader.java +++ b/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/database/JdbcCursorItemReader.java @@ -14,7 +14,7 @@ * limitations under the License. */ -package org.springframework.batch.io.cursor; +package org.springframework.batch.item.database; import java.sql.Connection; import java.sql.ResultSet; @@ -28,12 +28,12 @@ import javax.sql.DataSource; import org.apache.commons.logging.Log; import org.apache.commons.logging.LogFactory; -import org.springframework.batch.io.Skippable; import org.springframework.batch.item.ExecutionContext; import org.springframework.batch.item.ExecutionContextUserSupport; import org.springframework.batch.item.ItemReader; import org.springframework.batch.item.ItemStream; import org.springframework.batch.item.ResetFailedException; +import org.springframework.batch.item.Skippable; import org.springframework.beans.factory.InitializingBean; import org.springframework.dao.DataAccessException; import org.springframework.dao.InvalidDataAccessResourceUsageException; diff --git a/spring-batch-infrastructure/src/main/java/org/springframework/batch/io/driving/KeyGenerator.java b/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/database/KeyGenerator.java similarity index 93% rename from spring-batch-infrastructure/src/main/java/org/springframework/batch/io/driving/KeyGenerator.java rename to spring-batch-infrastructure/src/main/java/org/springframework/batch/item/database/KeyGenerator.java index 145ed4403..515c092b5 100644 --- a/spring-batch-infrastructure/src/main/java/org/springframework/batch/io/driving/KeyGenerator.java +++ b/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/database/KeyGenerator.java @@ -1,4 +1,4 @@ -package org.springframework.batch.io.driving; +package org.springframework.batch.item.database; import java.util.List; diff --git a/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/database/package.html b/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/database/package.html new file mode 100644 index 000000000..c73e51f88 --- /dev/null +++ b/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/database/package.html @@ -0,0 +1,7 @@ + + +

+Infrastructure implementations of database based item readers and writers. +

+ + diff --git a/spring-batch-infrastructure/src/main/java/org/springframework/batch/io/driving/support/ColumnMapExecutionContextRowMapper.java b/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/database/support/ColumnMapExecutionContextRowMapper.java similarity index 98% rename from spring-batch-infrastructure/src/main/java/org/springframework/batch/io/driving/support/ColumnMapExecutionContextRowMapper.java rename to spring-batch-infrastructure/src/main/java/org/springframework/batch/item/database/support/ColumnMapExecutionContextRowMapper.java index fc186ab8c..b9b4d90ed 100644 --- a/spring-batch-infrastructure/src/main/java/org/springframework/batch/io/driving/support/ColumnMapExecutionContextRowMapper.java +++ b/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/database/support/ColumnMapExecutionContextRowMapper.java @@ -1,7 +1,7 @@ /** * */ -package org.springframework.batch.io.driving.support; +package org.springframework.batch.item.database.support; import java.sql.PreparedStatement; import java.sql.SQLException; diff --git a/spring-batch-infrastructure/src/main/java/org/springframework/batch/io/driving/support/ExecutionContextRowMapper.java b/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/database/support/ExecutionContextRowMapper.java similarity index 97% rename from spring-batch-infrastructure/src/main/java/org/springframework/batch/io/driving/support/ExecutionContextRowMapper.java rename to spring-batch-infrastructure/src/main/java/org/springframework/batch/item/database/support/ExecutionContextRowMapper.java index d03efa959..a4836e4fc 100644 --- a/spring-batch-infrastructure/src/main/java/org/springframework/batch/io/driving/support/ExecutionContextRowMapper.java +++ b/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/database/support/ExecutionContextRowMapper.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package org.springframework.batch.io.driving.support; +package org.springframework.batch.item.database.support; import org.springframework.batch.item.ExecutionContext; import org.springframework.jdbc.core.PreparedStatementSetter; diff --git a/spring-batch-infrastructure/src/main/java/org/springframework/batch/io/driving/support/IbatisKeyGenerator.java b/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/database/support/IbatisKeyGenerator.java similarity index 94% rename from spring-batch-infrastructure/src/main/java/org/springframework/batch/io/driving/support/IbatisKeyGenerator.java rename to spring-batch-infrastructure/src/main/java/org/springframework/batch/item/database/support/IbatisKeyGenerator.java index 7bb48de11..a6776cd5a 100644 --- a/spring-batch-infrastructure/src/main/java/org/springframework/batch/io/driving/support/IbatisKeyGenerator.java +++ b/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/database/support/IbatisKeyGenerator.java @@ -1,11 +1,11 @@ -package org.springframework.batch.io.driving.support; +package org.springframework.batch.item.database.support; import java.util.List; -import org.springframework.batch.io.driving.DrivingQueryItemReader; -import org.springframework.batch.io.driving.KeyGenerator; import org.springframework.batch.item.ExecutionContext; import org.springframework.batch.item.ExecutionContextUserSupport; +import org.springframework.batch.item.database.DrivingQueryItemReader; +import org.springframework.batch.item.database.KeyGenerator; import org.springframework.orm.ibatis.SqlMapClientTemplate; import org.springframework.util.Assert; diff --git a/spring-batch-infrastructure/src/main/java/org/springframework/batch/io/driving/support/MultipleColumnJdbcKeyGenerator.java b/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/database/support/MultipleColumnJdbcKeyGenerator.java similarity index 95% rename from spring-batch-infrastructure/src/main/java/org/springframework/batch/io/driving/support/MultipleColumnJdbcKeyGenerator.java rename to spring-batch-infrastructure/src/main/java/org/springframework/batch/item/database/support/MultipleColumnJdbcKeyGenerator.java index adfc38c57..c65feece1 100644 --- a/spring-batch-infrastructure/src/main/java/org/springframework/batch/io/driving/support/MultipleColumnJdbcKeyGenerator.java +++ b/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/database/support/MultipleColumnJdbcKeyGenerator.java @@ -13,13 +13,13 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package org.springframework.batch.io.driving.support; +package org.springframework.batch.item.database.support; import java.util.List; -import org.springframework.batch.io.driving.DrivingQueryItemReader; -import org.springframework.batch.io.driving.KeyGenerator; import org.springframework.batch.item.ExecutionContext; +import org.springframework.batch.item.database.DrivingQueryItemReader; +import org.springframework.batch.item.database.KeyGenerator; import org.springframework.jdbc.core.JdbcTemplate; import org.springframework.util.Assert; import org.springframework.util.StringUtils; diff --git a/spring-batch-infrastructure/src/main/java/org/springframework/batch/io/driving/support/SingleColumnJdbcKeyGenerator.java b/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/database/support/SingleColumnJdbcKeyGenerator.java similarity index 97% rename from spring-batch-infrastructure/src/main/java/org/springframework/batch/io/driving/support/SingleColumnJdbcKeyGenerator.java rename to spring-batch-infrastructure/src/main/java/org/springframework/batch/item/database/support/SingleColumnJdbcKeyGenerator.java index 2b7f0bb56..035fe14df 100644 --- a/spring-batch-infrastructure/src/main/java/org/springframework/batch/io/driving/support/SingleColumnJdbcKeyGenerator.java +++ b/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/database/support/SingleColumnJdbcKeyGenerator.java @@ -13,13 +13,13 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package org.springframework.batch.io.driving.support; +package org.springframework.batch.item.database.support; import java.util.List; -import org.springframework.batch.io.driving.KeyGenerator; import org.springframework.batch.item.ExecutionContext; import org.springframework.batch.item.ExecutionContextUserSupport; +import org.springframework.batch.item.database.KeyGenerator; import org.springframework.jdbc.core.JdbcTemplate; import org.springframework.jdbc.core.RowMapper; import org.springframework.jdbc.core.SingleColumnRowMapper; diff --git a/spring-batch-infrastructure/src/main/java/org/springframework/batch/io/file/FlatFileItemReader.java b/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/file/FlatFileItemReader.java similarity index 94% rename from spring-batch-infrastructure/src/main/java/org/springframework/batch/io/file/FlatFileItemReader.java rename to spring-batch-infrastructure/src/main/java/org/springframework/batch/item/file/FlatFileItemReader.java index 163156a8b..63efc775a 100644 --- a/spring-batch-infrastructure/src/main/java/org/springframework/batch/io/file/FlatFileItemReader.java +++ b/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/file/FlatFileItemReader.java @@ -14,7 +14,7 @@ * limitations under the License. */ -package org.springframework.batch.io.file; +package org.springframework.batch.item.file; import java.io.IOException; import java.util.HashSet; @@ -22,16 +22,7 @@ import java.util.Set; import org.apache.commons.logging.Log; import org.apache.commons.logging.LogFactory; -import org.springframework.batch.io.Skippable; import org.springframework.batch.io.exception.FlatFileParsingException; -import org.springframework.batch.io.file.mapping.FieldSet; -import org.springframework.batch.io.file.mapping.FieldSetMapper; -import org.springframework.batch.io.file.separator.LineReader; -import org.springframework.batch.io.file.separator.RecordSeparatorPolicy; -import org.springframework.batch.io.file.separator.ResourceLineReader; -import org.springframework.batch.io.file.transform.AbstractLineTokenizer; -import org.springframework.batch.io.file.transform.DelimitedLineTokenizer; -import org.springframework.batch.io.file.transform.LineTokenizer; import org.springframework.batch.item.ExecutionContext; import org.springframework.batch.item.ExecutionContextUserSupport; import org.springframework.batch.item.ItemReader; @@ -39,6 +30,15 @@ import org.springframework.batch.item.ItemReaderException; import org.springframework.batch.item.ItemStream; import org.springframework.batch.item.ItemStreamException; import org.springframework.batch.item.ReaderNotOpenException; +import org.springframework.batch.item.Skippable; +import org.springframework.batch.item.file.mapping.FieldSet; +import org.springframework.batch.item.file.mapping.FieldSetMapper; +import org.springframework.batch.item.file.separator.LineReader; +import org.springframework.batch.item.file.separator.RecordSeparatorPolicy; +import org.springframework.batch.item.file.separator.ResourceLineReader; +import org.springframework.batch.item.file.transform.AbstractLineTokenizer; +import org.springframework.batch.item.file.transform.DelimitedLineTokenizer; +import org.springframework.batch.item.file.transform.LineTokenizer; import org.springframework.beans.factory.InitializingBean; import org.springframework.core.io.Resource; import org.springframework.util.Assert; diff --git a/spring-batch-infrastructure/src/main/java/org/springframework/batch/io/file/FlatFileItemWriter.java b/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/file/FlatFileItemWriter.java similarity index 97% rename from spring-batch-infrastructure/src/main/java/org/springframework/batch/io/file/FlatFileItemWriter.java rename to spring-batch-infrastructure/src/main/java/org/springframework/batch/item/file/FlatFileItemWriter.java index c89bf85a5..5634c47f4 100644 --- a/spring-batch-infrastructure/src/main/java/org/springframework/batch/io/file/FlatFileItemWriter.java +++ b/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/file/FlatFileItemWriter.java @@ -14,7 +14,7 @@ * limitations under the License. */ -package org.springframework.batch.io.file; +package org.springframework.batch.item.file; import java.io.BufferedWriter; import java.io.File; @@ -27,10 +27,6 @@ import java.nio.charset.UnsupportedCharsetException; import org.springframework.batch.io.exception.ConfigurationException; import org.springframework.batch.io.exception.InfrastructureException; -import org.springframework.batch.io.file.mapping.FieldSet; -import org.springframework.batch.io.file.mapping.FieldSetCreator; -import org.springframework.batch.io.file.transform.DelimitedLineAggregator; -import org.springframework.batch.io.file.transform.LineAggregator; import org.springframework.batch.item.ClearFailedException; import org.springframework.batch.item.ExecutionContext; import org.springframework.batch.item.ExecutionContextUserSupport; @@ -38,6 +34,10 @@ import org.springframework.batch.item.FlushFailedException; import org.springframework.batch.item.ItemStream; import org.springframework.batch.item.ItemStreamException; import org.springframework.batch.item.ItemWriter; +import org.springframework.batch.item.file.mapping.FieldSet; +import org.springframework.batch.item.file.mapping.FieldSetCreator; +import org.springframework.batch.item.file.transform.DelimitedLineAggregator; +import org.springframework.batch.item.file.transform.LineAggregator; import org.springframework.beans.factory.InitializingBean; import org.springframework.core.io.Resource; import org.springframework.dao.DataAccessResourceFailureException; diff --git a/spring-batch-infrastructure/src/main/java/org/springframework/batch/io/file/mapping/BeanWrapperFieldSetMapper.java b/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/file/mapping/BeanWrapperFieldSetMapper.java similarity index 98% rename from spring-batch-infrastructure/src/main/java/org/springframework/batch/io/file/mapping/BeanWrapperFieldSetMapper.java rename to spring-batch-infrastructure/src/main/java/org/springframework/batch/item/file/mapping/BeanWrapperFieldSetMapper.java index d67557fc7..01253c547 100644 --- a/spring-batch-infrastructure/src/main/java/org/springframework/batch/io/file/mapping/BeanWrapperFieldSetMapper.java +++ b/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/file/mapping/BeanWrapperFieldSetMapper.java @@ -14,7 +14,7 @@ * limitations under the License. */ -package org.springframework.batch.io.file.mapping; +package org.springframework.batch.item.file.mapping; import java.util.ArrayList; import java.util.HashMap; @@ -150,7 +150,7 @@ public class BeanWrapperFieldSetMapper extends DefaultPropertyEditorRegistrar im * the {@link DataBinder} from {@link #createBinder(Object)} has errors * after binding). * - * @see org.springframework.batch.io.file.mapping.FieldSetMapper#mapLine(org.springframework.batch.io.file.mapping.DefaultFieldSet) + * @see org.springframework.batch.item.file.mapping.FieldSetMapper#mapLine(org.springframework.batch.item.file.mapping.DefaultFieldSet) */ public Object mapLine(FieldSet fs) { Object copy = getBean(); diff --git a/spring-batch-infrastructure/src/main/java/org/springframework/batch/io/file/mapping/BindingException.java b/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/file/mapping/BindingException.java similarity index 93% rename from spring-batch-infrastructure/src/main/java/org/springframework/batch/io/file/mapping/BindingException.java rename to spring-batch-infrastructure/src/main/java/org/springframework/batch/item/file/mapping/BindingException.java index 758bc35c8..956ebf2ff 100644 --- a/spring-batch-infrastructure/src/main/java/org/springframework/batch/io/file/mapping/BindingException.java +++ b/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/file/mapping/BindingException.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package org.springframework.batch.io.file.mapping; +package org.springframework.batch.item.file.mapping; /** * @author Dave Syer diff --git a/spring-batch-infrastructure/src/main/java/org/springframework/batch/io/file/mapping/DefaultFieldSet.java b/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/file/mapping/DefaultFieldSet.java similarity index 99% rename from spring-batch-infrastructure/src/main/java/org/springframework/batch/io/file/mapping/DefaultFieldSet.java rename to spring-batch-infrastructure/src/main/java/org/springframework/batch/item/file/mapping/DefaultFieldSet.java index bbca4a3a8..470726ccc 100644 --- a/spring-batch-infrastructure/src/main/java/org/springframework/batch/io/file/mapping/DefaultFieldSet.java +++ b/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/file/mapping/DefaultFieldSet.java @@ -14,7 +14,7 @@ * limitations under the License. */ -package org.springframework.batch.io.file.mapping; +package org.springframework.batch.item.file.mapping; import java.math.BigDecimal; import java.text.ParseException; diff --git a/spring-batch-infrastructure/src/main/java/org/springframework/batch/io/file/mapping/FieldSet.java b/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/file/mapping/FieldSet.java similarity index 99% rename from spring-batch-infrastructure/src/main/java/org/springframework/batch/io/file/mapping/FieldSet.java rename to spring-batch-infrastructure/src/main/java/org/springframework/batch/item/file/mapping/FieldSet.java index c40b50a6b..4e113533d 100644 --- a/spring-batch-infrastructure/src/main/java/org/springframework/batch/io/file/mapping/FieldSet.java +++ b/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/file/mapping/FieldSet.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package org.springframework.batch.io.file.mapping; +package org.springframework.batch.item.file.mapping; import java.math.BigDecimal; import java.sql.ResultSet; diff --git a/spring-batch-infrastructure/src/main/java/org/springframework/batch/io/file/mapping/FieldSetCreator.java b/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/file/mapping/FieldSetCreator.java similarity index 89% rename from spring-batch-infrastructure/src/main/java/org/springframework/batch/io/file/mapping/FieldSetCreator.java rename to spring-batch-infrastructure/src/main/java/org/springframework/batch/item/file/mapping/FieldSetCreator.java index ea481ec58..4df3d864f 100644 --- a/spring-batch-infrastructure/src/main/java/org/springframework/batch/io/file/mapping/FieldSetCreator.java +++ b/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/file/mapping/FieldSetCreator.java @@ -13,9 +13,9 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package org.springframework.batch.io.file.mapping; +package org.springframework.batch.item.file.mapping; -import org.springframework.batch.io.file.transform.LineTokenizer; +import org.springframework.batch.item.file.transform.LineTokenizer; /** * Strategy interface for mapping between arbitrary objects and {@link FieldSet}. diff --git a/spring-batch-infrastructure/src/main/java/org/springframework/batch/io/file/mapping/FieldSetMapper.java b/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/file/mapping/FieldSetMapper.java similarity index 94% rename from spring-batch-infrastructure/src/main/java/org/springframework/batch/io/file/mapping/FieldSetMapper.java rename to spring-batch-infrastructure/src/main/java/org/springframework/batch/item/file/mapping/FieldSetMapper.java index 5f1a43358..4b4cde966 100644 --- a/spring-batch-infrastructure/src/main/java/org/springframework/batch/io/file/mapping/FieldSetMapper.java +++ b/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/file/mapping/FieldSetMapper.java @@ -14,7 +14,7 @@ * limitations under the License. */ -package org.springframework.batch.io.file.mapping; +package org.springframework.batch.item.file.mapping; /** diff --git a/spring-batch-infrastructure/src/main/java/org/springframework/batch/io/file/mapping/PassThroughFieldSetMapper.java b/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/file/mapping/PassThroughFieldSetMapper.java similarity index 90% rename from spring-batch-infrastructure/src/main/java/org/springframework/batch/io/file/mapping/PassThroughFieldSetMapper.java rename to spring-batch-infrastructure/src/main/java/org/springframework/batch/item/file/mapping/PassThroughFieldSetMapper.java index 2a92c073b..d96e5f3b1 100644 --- a/spring-batch-infrastructure/src/main/java/org/springframework/batch/io/file/mapping/PassThroughFieldSetMapper.java +++ b/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/file/mapping/PassThroughFieldSetMapper.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package org.springframework.batch.io.file.mapping; +package org.springframework.batch.item.file.mapping; /** @@ -38,7 +38,7 @@ public class PassThroughFieldSetMapper implements FieldSetMapper, FieldSetCreato * convert to a String with toString() and convert it to a single field * {@link FieldSet}. * - * @see org.springframework.batch.io.file.mapping.FieldSetCreator#mapItem(java.lang.Object) + * @see org.springframework.batch.item.file.mapping.FieldSetCreator#mapItem(java.lang.Object) */ public FieldSet mapItem(Object data) { if (data instanceof FieldSet) { diff --git a/spring-batch-infrastructure/src/main/java/org/springframework/batch/io/file/mapping/PropertyMatches.java b/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/file/mapping/PropertyMatches.java similarity index 99% rename from spring-batch-infrastructure/src/main/java/org/springframework/batch/io/file/mapping/PropertyMatches.java rename to spring-batch-infrastructure/src/main/java/org/springframework/batch/item/file/mapping/PropertyMatches.java index b6dec50db..a374c04d4 100644 --- a/spring-batch-infrastructure/src/main/java/org/springframework/batch/io/file/mapping/PropertyMatches.java +++ b/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/file/mapping/PropertyMatches.java @@ -14,7 +14,7 @@ * limitations under the License. */ -package org.springframework.batch.io.file.mapping; +package org.springframework.batch.item.file.mapping; import java.beans.PropertyDescriptor; import java.util.ArrayList; diff --git a/spring-batch-infrastructure/src/main/java/org/springframework/batch/io/file/mapping/package.html b/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/file/mapping/package.html similarity index 100% rename from spring-batch-infrastructure/src/main/java/org/springframework/batch/io/file/mapping/package.html rename to spring-batch-infrastructure/src/main/java/org/springframework/batch/item/file/mapping/package.html diff --git a/spring-batch-infrastructure/src/main/java/org/springframework/batch/io/file/package.html b/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/file/package.html similarity index 100% rename from spring-batch-infrastructure/src/main/java/org/springframework/batch/io/file/package.html rename to spring-batch-infrastructure/src/main/java/org/springframework/batch/item/file/package.html diff --git a/spring-batch-infrastructure/src/main/java/org/springframework/batch/io/file/separator/DefaultRecordSeparatorPolicy.java b/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/file/separator/DefaultRecordSeparatorPolicy.java similarity index 92% rename from spring-batch-infrastructure/src/main/java/org/springframework/batch/io/file/separator/DefaultRecordSeparatorPolicy.java rename to spring-batch-infrastructure/src/main/java/org/springframework/batch/item/file/separator/DefaultRecordSeparatorPolicy.java index 9db8776aa..2392fdbe1 100644 --- a/spring-batch-infrastructure/src/main/java/org/springframework/batch/io/file/separator/DefaultRecordSeparatorPolicy.java +++ b/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/file/separator/DefaultRecordSeparatorPolicy.java @@ -14,7 +14,7 @@ * limitations under the License. */ -package org.springframework.batch.io.file.separator; +package org.springframework.batch.item.file.separator; import org.springframework.util.StringUtils; @@ -83,7 +83,7 @@ public class DefaultRecordSeparatorPolicy extends SimpleRecordSeparatorPolicy { * "), and does not end with a continuation marker ('\'). The test for the * continuation marker ignores whitespace at the end of the line. * - * @see org.springframework.batch.io.file.separator.RecordSeparatorPolicy#isEndOfRecord(java.lang.String) + * @see org.springframework.batch.item.file.separator.RecordSeparatorPolicy#isEndOfRecord(java.lang.String) */ public boolean isEndOfRecord(String line) { return !isQuoteUnterminated(line) && !isContinued(line); @@ -94,7 +94,7 @@ public class DefaultRecordSeparatorPolicy extends SimpleRecordSeparatorPolicy { * remove the continuation marker (plus whitespace at the end) if it is * there. * - * @see org.springframework.batch.io.file.separator.SimpleRecordSeparatorPolicy#preProcess(java.lang.String) + * @see org.springframework.batch.item.file.separator.SimpleRecordSeparatorPolicy#preProcess(java.lang.String) */ public String preProcess(String line) { if (isQuoteUnterminated(line)) { diff --git a/spring-batch-infrastructure/src/main/java/org/springframework/batch/io/file/separator/LineReader.java b/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/file/separator/LineReader.java similarity index 94% rename from spring-batch-infrastructure/src/main/java/org/springframework/batch/io/file/separator/LineReader.java rename to spring-batch-infrastructure/src/main/java/org/springframework/batch/item/file/separator/LineReader.java index 2e02a310d..ac27611f5 100644 --- a/spring-batch-infrastructure/src/main/java/org/springframework/batch/io/file/separator/LineReader.java +++ b/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/file/separator/LineReader.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package org.springframework.batch.io.file.separator; +package org.springframework.batch.item.file.separator; import org.springframework.batch.item.ItemReader; import org.springframework.batch.item.ItemStream; diff --git a/spring-batch-infrastructure/src/main/java/org/springframework/batch/io/file/separator/RecordSeparatorPolicy.java b/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/file/separator/RecordSeparatorPolicy.java similarity index 97% rename from spring-batch-infrastructure/src/main/java/org/springframework/batch/io/file/separator/RecordSeparatorPolicy.java rename to spring-batch-infrastructure/src/main/java/org/springframework/batch/item/file/separator/RecordSeparatorPolicy.java index 22c6b9b85..7a319e401 100644 --- a/spring-batch-infrastructure/src/main/java/org/springframework/batch/io/file/separator/RecordSeparatorPolicy.java +++ b/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/file/separator/RecordSeparatorPolicy.java @@ -14,7 +14,7 @@ * limitations under the License. */ -package org.springframework.batch.io.file.separator; +package org.springframework.batch.item.file.separator; import java.io.BufferedReader; diff --git a/spring-batch-infrastructure/src/main/java/org/springframework/batch/io/file/separator/ResourceLineReader.java b/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/file/separator/ResourceLineReader.java similarity index 97% rename from spring-batch-infrastructure/src/main/java/org/springframework/batch/io/file/separator/ResourceLineReader.java rename to spring-batch-infrastructure/src/main/java/org/springframework/batch/item/file/separator/ResourceLineReader.java index 1677953d3..8130fa093 100644 --- a/spring-batch-infrastructure/src/main/java/org/springframework/batch/io/file/separator/ResourceLineReader.java +++ b/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/file/separator/ResourceLineReader.java @@ -14,7 +14,7 @@ * limitations under the License. */ -package org.springframework.batch.io.file.separator; +package org.springframework.batch.item.file.separator; import java.io.BufferedReader; import java.io.IOException; @@ -29,10 +29,10 @@ import org.springframework.batch.item.ExecutionContext; import org.springframework.batch.item.ItemReader; import org.springframework.batch.item.ItemStream; import org.springframework.batch.item.ItemStreamException; +import org.springframework.batch.item.ItemStreamSupport; import org.springframework.batch.item.MarkFailedException; import org.springframework.batch.item.ResetFailedException; import org.springframework.batch.item.UnexpectedInputException; -import org.springframework.batch.item.stream.ItemStreamSupport; import org.springframework.core.io.Resource; import org.springframework.util.Assert; @@ -159,7 +159,7 @@ public class ResourceLineReader extends ItemStreamSupport implements LineReader, /** * Close the reader associated with this input source. * - * @see org.springframework.batch.item.stream.ItemStreamSupport#close(org.springframework.batch.item.ExecutionContext) + * @see org.springframework.batch.item.ItemStreamSupport#close(org.springframework.batch.item.ExecutionContext) */ public synchronized void close(ExecutionContext executionContext) { if (state == null) { diff --git a/spring-batch-infrastructure/src/main/java/org/springframework/batch/io/file/separator/SimpleRecordSeparatorPolicy.java b/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/file/separator/SimpleRecordSeparatorPolicy.java similarity index 75% rename from spring-batch-infrastructure/src/main/java/org/springframework/batch/io/file/separator/SimpleRecordSeparatorPolicy.java rename to spring-batch-infrastructure/src/main/java/org/springframework/batch/item/file/separator/SimpleRecordSeparatorPolicy.java index 5251a14a6..4751dd8c2 100644 --- a/spring-batch-infrastructure/src/main/java/org/springframework/batch/io/file/separator/SimpleRecordSeparatorPolicy.java +++ b/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/file/separator/SimpleRecordSeparatorPolicy.java @@ -14,7 +14,7 @@ * limitations under the License. */ -package org.springframework.batch.io.file.separator; +package org.springframework.batch.item.file.separator; /** @@ -29,7 +29,7 @@ public class SimpleRecordSeparatorPolicy implements RecordSeparatorPolicy { /** * Always returns true. * - * @see org.springframework.batch.io.file.separator.RecordSeparatorPolicy#isEndOfRecord(java.lang.String) + * @see org.springframework.batch.item.file.separator.RecordSeparatorPolicy#isEndOfRecord(java.lang.String) */ public boolean isEndOfRecord(String line) { return true; @@ -37,7 +37,7 @@ public class SimpleRecordSeparatorPolicy implements RecordSeparatorPolicy { /** * Pass the record through. Do nothing. - * @see org.springframework.batch.io.file.separator.RecordSeparatorPolicy#postProcess(java.lang.String) + * @see org.springframework.batch.item.file.separator.RecordSeparatorPolicy#postProcess(java.lang.String) */ public String postProcess(String record) { return record; @@ -45,7 +45,7 @@ public class SimpleRecordSeparatorPolicy implements RecordSeparatorPolicy { /** * Pass the line through. Do nothing. - * @see org.springframework.batch.io.file.separator.RecordSeparatorPolicy#preProcess(java.lang.String) + * @see org.springframework.batch.item.file.separator.RecordSeparatorPolicy#preProcess(java.lang.String) */ public String preProcess(String line) { return line; diff --git a/spring-batch-infrastructure/src/main/java/org/springframework/batch/io/file/separator/SuffixRecordSeparatorPolicy.java b/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/file/separator/SuffixRecordSeparatorPolicy.java similarity index 88% rename from spring-batch-infrastructure/src/main/java/org/springframework/batch/io/file/separator/SuffixRecordSeparatorPolicy.java rename to spring-batch-infrastructure/src/main/java/org/springframework/batch/item/file/separator/SuffixRecordSeparatorPolicy.java index 54f22a14c..b8147b4c4 100644 --- a/spring-batch-infrastructure/src/main/java/org/springframework/batch/io/file/separator/SuffixRecordSeparatorPolicy.java +++ b/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/file/separator/SuffixRecordSeparatorPolicy.java @@ -14,7 +14,7 @@ * limitations under the License. */ -package org.springframework.batch.io.file.separator; +package org.springframework.batch.item.file.separator; /** @@ -59,7 +59,7 @@ public class SuffixRecordSeparatorPolicy extends DefaultRecordSeparatorPolicy { * whitespace is trimmed before the comparison. Also returns true if the * line is null, but not if it is empty. * - * @see org.springframework.batch.io.file.separator.RecordSeparatorPolicy#isEndOfRecord(java.lang.String) + * @see org.springframework.batch.item.file.separator.RecordSeparatorPolicy#isEndOfRecord(java.lang.String) */ public boolean isEndOfRecord(String line) { if (line == null) { @@ -72,7 +72,7 @@ public class SuffixRecordSeparatorPolicy extends DefaultRecordSeparatorPolicy { /** * Remove the suffix from the end of the record. * - * @see org.springframework.batch.io.file.separator.SimpleRecordSeparatorPolicy#postProcess(java.lang.String) + * @see org.springframework.batch.item.file.separator.SimpleRecordSeparatorPolicy#postProcess(java.lang.String) */ public String postProcess(String record) { if (record==null) { diff --git a/spring-batch-infrastructure/src/main/java/org/springframework/batch/io/file/separator/package.html b/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/file/separator/package.html similarity index 100% rename from spring-batch-infrastructure/src/main/java/org/springframework/batch/io/file/separator/package.html rename to spring-batch-infrastructure/src/main/java/org/springframework/batch/item/file/separator/package.html diff --git a/spring-batch-infrastructure/src/main/java/org/springframework/batch/io/file/transform/AbstractLineTokenizer.java b/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/file/transform/AbstractLineTokenizer.java similarity index 91% rename from spring-batch-infrastructure/src/main/java/org/springframework/batch/io/file/transform/AbstractLineTokenizer.java rename to spring-batch-infrastructure/src/main/java/org/springframework/batch/item/file/transform/AbstractLineTokenizer.java index 0cccacf0d..586ffbf93 100644 --- a/spring-batch-infrastructure/src/main/java/org/springframework/batch/io/file/transform/AbstractLineTokenizer.java +++ b/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/file/transform/AbstractLineTokenizer.java @@ -14,13 +14,13 @@ * limitations under the License. */ -package org.springframework.batch.io.file.transform; +package org.springframework.batch.item.file.transform; import java.util.ArrayList; import java.util.List; -import org.springframework.batch.io.file.mapping.DefaultFieldSet; -import org.springframework.batch.io.file.mapping.FieldSet; +import org.springframework.batch.item.file.mapping.DefaultFieldSet; +import org.springframework.batch.item.file.mapping.FieldSet; /** diff --git a/spring-batch-infrastructure/src/main/java/org/springframework/batch/io/file/transform/ConversionException.java b/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/file/transform/ConversionException.java similarity index 93% rename from spring-batch-infrastructure/src/main/java/org/springframework/batch/io/file/transform/ConversionException.java rename to spring-batch-infrastructure/src/main/java/org/springframework/batch/item/file/transform/ConversionException.java index 046f3fde6..904d48bb1 100644 --- a/spring-batch-infrastructure/src/main/java/org/springframework/batch/io/file/transform/ConversionException.java +++ b/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/file/transform/ConversionException.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package org.springframework.batch.io.file.transform; +package org.springframework.batch.item.file.transform; /** * @author Dave Syer diff --git a/spring-batch-infrastructure/src/main/java/org/springframework/batch/io/file/transform/DelimitedLineAggregator.java b/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/file/transform/DelimitedLineAggregator.java similarity index 92% rename from spring-batch-infrastructure/src/main/java/org/springframework/batch/io/file/transform/DelimitedLineAggregator.java rename to spring-batch-infrastructure/src/main/java/org/springframework/batch/item/file/transform/DelimitedLineAggregator.java index ba1ee6ae6..c0bd716e9 100644 --- a/spring-batch-infrastructure/src/main/java/org/springframework/batch/io/file/transform/DelimitedLineAggregator.java +++ b/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/file/transform/DelimitedLineAggregator.java @@ -14,9 +14,9 @@ * limitations under the License. */ -package org.springframework.batch.io.file.transform; +package org.springframework.batch.item.file.transform; -import org.springframework.batch.io.file.mapping.FieldSet; +import org.springframework.batch.item.file.mapping.FieldSet; /** diff --git a/spring-batch-infrastructure/src/main/java/org/springframework/batch/io/file/transform/DelimitedLineTokenizer.java b/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/file/transform/DelimitedLineTokenizer.java similarity index 99% rename from spring-batch-infrastructure/src/main/java/org/springframework/batch/io/file/transform/DelimitedLineTokenizer.java rename to spring-batch-infrastructure/src/main/java/org/springframework/batch/item/file/transform/DelimitedLineTokenizer.java index cdd24590b..f3ab0e05b 100644 --- a/spring-batch-infrastructure/src/main/java/org/springframework/batch/io/file/transform/DelimitedLineTokenizer.java +++ b/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/file/transform/DelimitedLineTokenizer.java @@ -14,7 +14,7 @@ * limitations under the License. */ -package org.springframework.batch.io.file.transform; +package org.springframework.batch.item.file.transform; import java.util.ArrayList; import java.util.List; diff --git a/spring-batch-infrastructure/src/main/java/org/springframework/batch/io/file/transform/FixedLengthLineAggregator.java b/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/file/transform/FixedLengthLineAggregator.java similarity index 97% rename from spring-batch-infrastructure/src/main/java/org/springframework/batch/io/file/transform/FixedLengthLineAggregator.java rename to spring-batch-infrastructure/src/main/java/org/springframework/batch/item/file/transform/FixedLengthLineAggregator.java index 023cfc9f5..02c9b812a 100644 --- a/spring-batch-infrastructure/src/main/java/org/springframework/batch/io/file/transform/FixedLengthLineAggregator.java +++ b/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/file/transform/FixedLengthLineAggregator.java @@ -14,11 +14,11 @@ * limitations under the License. */ -package org.springframework.batch.io.file.transform; +package org.springframework.batch.item.file.transform; import java.util.Arrays; -import org.springframework.batch.io.file.mapping.FieldSet; +import org.springframework.batch.item.file.mapping.FieldSet; import org.springframework.util.Assert; /** diff --git a/spring-batch-infrastructure/src/main/java/org/springframework/batch/io/file/transform/FixedLengthTokenizer.java b/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/file/transform/FixedLengthTokenizer.java similarity index 97% rename from spring-batch-infrastructure/src/main/java/org/springframework/batch/io/file/transform/FixedLengthTokenizer.java rename to spring-batch-infrastructure/src/main/java/org/springframework/batch/item/file/transform/FixedLengthTokenizer.java index ed6f8d7ae..b822d245f 100644 --- a/spring-batch-infrastructure/src/main/java/org/springframework/batch/io/file/transform/FixedLengthTokenizer.java +++ b/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/file/transform/FixedLengthTokenizer.java @@ -14,7 +14,7 @@ * limitations under the License. */ -package org.springframework.batch.io.file.transform; +package org.springframework.batch.item.file.transform; import java.util.ArrayList; import java.util.List; diff --git a/spring-batch-infrastructure/src/main/java/org/springframework/batch/io/file/transform/LineAggregator.java b/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/file/transform/LineAggregator.java similarity index 89% rename from spring-batch-infrastructure/src/main/java/org/springframework/batch/io/file/transform/LineAggregator.java rename to spring-batch-infrastructure/src/main/java/org/springframework/batch/item/file/transform/LineAggregator.java index 718e0dc5a..06ffcb67e 100644 --- a/spring-batch-infrastructure/src/main/java/org/springframework/batch/io/file/transform/LineAggregator.java +++ b/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/file/transform/LineAggregator.java @@ -14,9 +14,9 @@ * limitations under the License. */ -package org.springframework.batch.io.file.transform; +package org.springframework.batch.item.file.transform; -import org.springframework.batch.io.file.mapping.FieldSet; +import org.springframework.batch.item.file.mapping.FieldSet; /** diff --git a/spring-batch-infrastructure/src/main/java/org/springframework/batch/io/file/transform/LineAggregatorItemTransformer.java b/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/file/transform/LineAggregatorItemTransformer.java similarity index 85% rename from spring-batch-infrastructure/src/main/java/org/springframework/batch/io/file/transform/LineAggregatorItemTransformer.java rename to spring-batch-infrastructure/src/main/java/org/springframework/batch/item/file/transform/LineAggregatorItemTransformer.java index 45e270299..855c9468d 100644 --- a/spring-batch-infrastructure/src/main/java/org/springframework/batch/io/file/transform/LineAggregatorItemTransformer.java +++ b/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/file/transform/LineAggregatorItemTransformer.java @@ -13,11 +13,11 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package org.springframework.batch.io.file.transform; +package org.springframework.batch.item.file.transform; -import org.springframework.batch.io.file.mapping.DefaultFieldSet; -import org.springframework.batch.io.file.mapping.FieldSet; -import org.springframework.batch.item.writer.ItemTransformer; +import org.springframework.batch.item.file.mapping.DefaultFieldSet; +import org.springframework.batch.item.file.mapping.FieldSet; +import org.springframework.batch.item.transform.ItemTransformer; /** * An {@link ItemTransformer} that expects a String[] as input and delegates to @@ -42,7 +42,7 @@ public class LineAggregatorItemTransformer implements ItemTransformer { * Assume the item is an array of String (no check is made) and delegate to * the aggregator. * - * @see org.springframework.batch.item.writer.ItemTransformer#transform(java.lang.Object) + * @see org.springframework.batch.item.transform.ItemTransformer#transform(java.lang.Object) */ public Object transform(Object item) throws Exception { return aggregator.aggregate(createFieldSet(item)); diff --git a/spring-batch-infrastructure/src/main/java/org/springframework/batch/io/file/transform/LineTokenizer.java b/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/file/transform/LineTokenizer.java similarity index 90% rename from spring-batch-infrastructure/src/main/java/org/springframework/batch/io/file/transform/LineTokenizer.java rename to spring-batch-infrastructure/src/main/java/org/springframework/batch/item/file/transform/LineTokenizer.java index 736048e41..853e42ee2 100644 --- a/spring-batch-infrastructure/src/main/java/org/springframework/batch/io/file/transform/LineTokenizer.java +++ b/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/file/transform/LineTokenizer.java @@ -14,9 +14,9 @@ * limitations under the License. */ -package org.springframework.batch.io.file.transform; +package org.springframework.batch.item.file.transform; -import org.springframework.batch.io.file.mapping.FieldSet; +import org.springframework.batch.item.file.mapping.FieldSet; /** diff --git a/spring-batch-infrastructure/src/main/java/org/springframework/batch/io/file/transform/PrefixMatchingCompositeLineTokenizer.java b/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/file/transform/PrefixMatchingCompositeLineTokenizer.java similarity index 90% rename from spring-batch-infrastructure/src/main/java/org/springframework/batch/io/file/transform/PrefixMatchingCompositeLineTokenizer.java rename to spring-batch-infrastructure/src/main/java/org/springframework/batch/item/file/transform/PrefixMatchingCompositeLineTokenizer.java index cad1aa67c..38ba8c79f 100644 --- a/spring-batch-infrastructure/src/main/java/org/springframework/batch/io/file/transform/PrefixMatchingCompositeLineTokenizer.java +++ b/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/file/transform/PrefixMatchingCompositeLineTokenizer.java @@ -14,15 +14,15 @@ * limitations under the License. */ -package org.springframework.batch.io.file.transform; +package org.springframework.batch.item.file.transform; import java.util.HashMap; import java.util.Iterator; import java.util.LinkedHashMap; import java.util.Map; -import org.springframework.batch.io.file.mapping.DefaultFieldSet; -import org.springframework.batch.io.file.mapping.FieldSet; +import org.springframework.batch.item.file.mapping.DefaultFieldSet; +import org.springframework.batch.item.file.mapping.FieldSet; public class PrefixMatchingCompositeLineTokenizer implements LineTokenizer { diff --git a/spring-batch-infrastructure/src/main/java/org/springframework/batch/io/file/transform/Range.java b/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/file/transform/Range.java similarity index 96% rename from spring-batch-infrastructure/src/main/java/org/springframework/batch/io/file/transform/Range.java rename to spring-batch-infrastructure/src/main/java/org/springframework/batch/item/file/transform/Range.java index 10fd33eb5..798568f93 100644 --- a/spring-batch-infrastructure/src/main/java/org/springframework/batch/io/file/transform/Range.java +++ b/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/file/transform/Range.java @@ -1,4 +1,4 @@ -package org.springframework.batch.io.file.transform; +package org.springframework.batch.item.file.transform; import org.springframework.util.Assert; diff --git a/spring-batch-infrastructure/src/main/java/org/springframework/batch/io/file/transform/RangeArrayPropertyEditor.java b/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/file/transform/RangeArrayPropertyEditor.java similarity index 98% rename from spring-batch-infrastructure/src/main/java/org/springframework/batch/io/file/transform/RangeArrayPropertyEditor.java rename to spring-batch-infrastructure/src/main/java/org/springframework/batch/item/file/transform/RangeArrayPropertyEditor.java index 60bf14061..790703798 100644 --- a/spring-batch-infrastructure/src/main/java/org/springframework/batch/io/file/transform/RangeArrayPropertyEditor.java +++ b/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/file/transform/RangeArrayPropertyEditor.java @@ -1,4 +1,4 @@ -package org.springframework.batch.io.file.transform; +package org.springframework.batch.item.file.transform; import java.beans.PropertyEditorSupport; import java.util.Arrays; diff --git a/spring-batch-infrastructure/src/main/java/org/springframework/batch/io/file/transform/RecursiveCollectionItemTransformer.java b/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/file/transform/RecursiveCollectionItemTransformer.java similarity index 96% rename from spring-batch-infrastructure/src/main/java/org/springframework/batch/io/file/transform/RecursiveCollectionItemTransformer.java rename to spring-batch-infrastructure/src/main/java/org/springframework/batch/item/file/transform/RecursiveCollectionItemTransformer.java index 0980b06d0..589aa92ab 100644 --- a/spring-batch-infrastructure/src/main/java/org/springframework/batch/io/file/transform/RecursiveCollectionItemTransformer.java +++ b/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/file/transform/RecursiveCollectionItemTransformer.java @@ -1,9 +1,9 @@ -package org.springframework.batch.io.file.transform; +package org.springframework.batch.item.file.transform; import java.util.Collection; import java.util.Iterator; -import org.springframework.batch.item.writer.ItemTransformer; +import org.springframework.batch.item.transform.ItemTransformer; /** * An implementation of {@link ItemTransformer} that treats its argument diff --git a/spring-batch-infrastructure/src/main/java/org/springframework/batch/io/file/transform/package.html b/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/file/transform/package.html similarity index 100% rename from spring-batch-infrastructure/src/main/java/org/springframework/batch/io/file/transform/package.html rename to spring-batch-infrastructure/src/main/java/org/springframework/batch/item/file/transform/package.html diff --git a/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/reader/AggregateItemReader.java b/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/reader/AggregateItemReader.java index 6e4f1d514..c17c46478 100644 --- a/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/reader/AggregateItemReader.java +++ b/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/reader/AggregateItemReader.java @@ -21,8 +21,8 @@ import java.util.Collection; import org.apache.commons.logging.Log; import org.apache.commons.logging.LogFactory; -import org.springframework.batch.io.file.mapping.FieldSetMapper; import org.springframework.batch.item.ItemReader; +import org.springframework.batch.item.file.mapping.FieldSetMapper; /** * An {@link ItemReader} that delivers a list as its item, storing up objects diff --git a/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/reader/DelegatingItemReader.java b/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/reader/DelegatingItemReader.java index 59aafd0ed..dfaa3cf82 100644 --- a/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/reader/DelegatingItemReader.java +++ b/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/reader/DelegatingItemReader.java @@ -16,8 +16,9 @@ package org.springframework.batch.item.reader; -import org.springframework.batch.io.Skippable; +import org.springframework.batch.item.AbstractItemReader; import org.springframework.batch.item.ItemReader; +import org.springframework.batch.item.Skippable; import org.springframework.beans.factory.InitializingBean; import org.springframework.util.Assert; diff --git a/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/reader/JmsItemReader.java b/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/reader/JmsItemReader.java index a864d8bd3..f9decdc9a 100644 --- a/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/reader/JmsItemReader.java +++ b/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/reader/JmsItemReader.java @@ -22,6 +22,7 @@ import javax.jms.Message; import org.apache.commons.logging.Log; import org.apache.commons.logging.LogFactory; +import org.springframework.batch.item.AbstractItemReader; import org.springframework.batch.item.FailedItemIdentifier; import org.springframework.batch.item.ItemKeyGenerator; import org.springframework.batch.item.ItemReader; @@ -110,7 +111,7 @@ public class JmsItemReader extends AbstractItemReader implements ItemRecoverer, * Send the message back to the proovider using the specified error * destination property of this provider. * - * @see org.springframework.batch.item.reader.AbstractItemReader#recover(java.lang.Object, + * @see org.springframework.batch.item.AbstractItemReader#recover(java.lang.Object, * Throwable) */ public boolean recover(Object item, Throwable cause) { @@ -139,7 +140,7 @@ public class JmsItemReader extends AbstractItemReader implements ItemRecoverer, * If the message is a {@link Message} then returns the JMS message ID. * Otherwise just delegate to parent class. * - * @see org.springframework.batch.item.reader.AbstractItemReader#getKey(java.lang.Object) + * @see org.springframework.batch.item.AbstractItemReader#getKey(java.lang.Object) * * @throws UnexpectedInputException if the JMS id cannot be determined from * a JMS Message diff --git a/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/reader/ListItemReader.java b/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/reader/ListItemReader.java index 538daede6..30a2149d5 100644 --- a/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/reader/ListItemReader.java +++ b/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/reader/ListItemReader.java @@ -20,6 +20,7 @@ import java.util.ArrayList; import java.util.List; import org.springframework.aop.support.AopUtils; +import org.springframework.batch.item.AbstractItemReader; import org.springframework.batch.item.ItemReader; /** diff --git a/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/stream/package.html b/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/stream/package.html new file mode 100644 index 000000000..ed777249f --- /dev/null +++ b/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/stream/package.html @@ -0,0 +1,7 @@ + + +

+Generic implementations of ItemStream +

+ + diff --git a/spring-batch-infrastructure/src/main/java/org/springframework/batch/io/support/FileUtils.java b/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/support/FileUtils.java similarity index 97% rename from spring-batch-infrastructure/src/main/java/org/springframework/batch/io/support/FileUtils.java rename to spring-batch-infrastructure/src/main/java/org/springframework/batch/item/support/FileUtils.java index 82f2e79d7..b516a0b3a 100644 --- a/spring-batch-infrastructure/src/main/java/org/springframework/batch/io/support/FileUtils.java +++ b/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/support/FileUtils.java @@ -1,4 +1,4 @@ -package org.springframework.batch.io.support; +package org.springframework.batch.item.support; import java.io.File; import java.io.IOException; diff --git a/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/support/package.html b/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/support/package.html new file mode 100644 index 000000000..ca70983df --- /dev/null +++ b/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/support/package.html @@ -0,0 +1,7 @@ + + +

+Internal support package +

+ + diff --git a/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/writer/CompositeItemTransformer.java b/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/transform/CompositeItemTransformer.java similarity index 96% rename from spring-batch-infrastructure/src/main/java/org/springframework/batch/item/writer/CompositeItemTransformer.java rename to spring-batch-infrastructure/src/main/java/org/springframework/batch/item/transform/CompositeItemTransformer.java index b68116404..c35659d53 100644 --- a/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/writer/CompositeItemTransformer.java +++ b/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/transform/CompositeItemTransformer.java @@ -1,4 +1,4 @@ -package org.springframework.batch.item.writer; +package org.springframework.batch.item.transform; import java.util.Iterator; import java.util.List; diff --git a/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/writer/ItemTransformer.java b/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/transform/ItemTransformer.java similarity index 79% rename from spring-batch-infrastructure/src/main/java/org/springframework/batch/item/writer/ItemTransformer.java rename to spring-batch-infrastructure/src/main/java/org/springframework/batch/item/transform/ItemTransformer.java index 0c2946be9..55f9c47c5 100644 --- a/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/writer/ItemTransformer.java +++ b/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/transform/ItemTransformer.java @@ -1,4 +1,4 @@ -package org.springframework.batch.item.writer; +package org.springframework.batch.item.transform; /** * Interface for item transformations during processing phase. diff --git a/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/writer/ItemTransformerItemWriter.java b/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/transform/ItemTransformerItemWriter.java similarity index 88% rename from spring-batch-infrastructure/src/main/java/org/springframework/batch/item/writer/ItemTransformerItemWriter.java rename to spring-batch-infrastructure/src/main/java/org/springframework/batch/item/transform/ItemTransformerItemWriter.java index a33f58dfd..baf45b39f 100644 --- a/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/writer/ItemTransformerItemWriter.java +++ b/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/transform/ItemTransformerItemWriter.java @@ -1,6 +1,7 @@ -package org.springframework.batch.item.writer; +package org.springframework.batch.item.transform; import org.springframework.batch.item.ItemWriter; +import org.springframework.batch.item.writer.DelegatingItemWriter; import org.springframework.util.Assert; /** diff --git a/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/transform/package.html b/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/transform/package.html new file mode 100644 index 000000000..a07f60145 --- /dev/null +++ b/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/transform/package.html @@ -0,0 +1,7 @@ + + +

+Writer implementation concerned with item transformation before writing. +

+ + diff --git a/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/reader/ValidatingItemReader.java b/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/validator/ValidatingItemReader.java similarity index 93% rename from spring-batch-infrastructure/src/main/java/org/springframework/batch/item/reader/ValidatingItemReader.java rename to spring-batch-infrastructure/src/main/java/org/springframework/batch/item/validator/ValidatingItemReader.java index 53877ff14..fb661b5fd 100644 --- a/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/reader/ValidatingItemReader.java +++ b/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/validator/ValidatingItemReader.java @@ -13,9 +13,9 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package org.springframework.batch.item.reader; +package org.springframework.batch.item.validator; -import org.springframework.batch.item.validator.Validator; +import org.springframework.batch.item.reader.DelegatingItemReader; import org.springframework.util.Assert; /** diff --git a/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/writer/CompositeItemWriter.java b/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/writer/CompositeItemWriter.java index dc87eb926..83afbdc3c 100644 --- a/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/writer/CompositeItemWriter.java +++ b/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/writer/CompositeItemWriter.java @@ -3,6 +3,7 @@ package org.springframework.batch.item.writer; import java.util.Iterator; import java.util.List; +import org.springframework.batch.item.AbstractItemWriter; import org.springframework.batch.item.ItemWriter; /** diff --git a/spring-batch-infrastructure/src/main/java/org/springframework/batch/io/xml/EventReaderDeserializer.java b/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/xml/EventReaderDeserializer.java similarity index 87% rename from spring-batch-infrastructure/src/main/java/org/springframework/batch/io/xml/EventReaderDeserializer.java rename to spring-batch-infrastructure/src/main/java/org/springframework/batch/item/xml/EventReaderDeserializer.java index 1036ca244..cf1bafd4f 100644 --- a/spring-batch-infrastructure/src/main/java/org/springframework/batch/io/xml/EventReaderDeserializer.java +++ b/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/xml/EventReaderDeserializer.java @@ -1,4 +1,4 @@ -package org.springframework.batch.io.xml; +package org.springframework.batch.item.xml; import javax.xml.stream.XMLEventReader; diff --git a/spring-batch-infrastructure/src/main/java/org/springframework/batch/io/xml/EventWriterSerializer.java b/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/xml/EventWriterSerializer.java similarity index 90% rename from spring-batch-infrastructure/src/main/java/org/springframework/batch/io/xml/EventWriterSerializer.java rename to spring-batch-infrastructure/src/main/java/org/springframework/batch/item/xml/EventWriterSerializer.java index e2dbde177..089768adb 100644 --- a/spring-batch-infrastructure/src/main/java/org/springframework/batch/io/xml/EventWriterSerializer.java +++ b/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/xml/EventWriterSerializer.java @@ -1,4 +1,4 @@ -package org.springframework.batch.io.xml; +package org.springframework.batch.item.xml; import javax.xml.stream.XMLEventWriter; diff --git a/spring-batch-infrastructure/src/main/java/org/springframework/batch/io/xml/StaxEventItemReader.java b/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/xml/StaxEventItemReader.java similarity index 94% rename from spring-batch-infrastructure/src/main/java/org/springframework/batch/io/xml/StaxEventItemReader.java rename to spring-batch-infrastructure/src/main/java/org/springframework/batch/item/xml/StaxEventItemReader.java index bcecc3081..155afb761 100644 --- a/spring-batch-infrastructure/src/main/java/org/springframework/batch/io/xml/StaxEventItemReader.java +++ b/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/xml/StaxEventItemReader.java @@ -1,4 +1,4 @@ -package org.springframework.batch.io.xml; +package org.springframework.batch.item.xml; import java.io.IOException; import java.io.InputStream; @@ -11,17 +11,17 @@ import javax.xml.stream.XMLInputFactory; import javax.xml.stream.XMLStreamException; import javax.xml.stream.events.StartElement; -import org.springframework.batch.io.Skippable; -import org.springframework.batch.io.xml.stax.DefaultFragmentEventReader; -import org.springframework.batch.io.xml.stax.DefaultTransactionalEventReader; -import org.springframework.batch.io.xml.stax.FragmentEventReader; -import org.springframework.batch.io.xml.stax.TransactionalEventReader; import org.springframework.batch.item.ExecutionContext; import org.springframework.batch.item.ExecutionContextUserSupport; import org.springframework.batch.item.ItemReader; import org.springframework.batch.item.ItemStream; import org.springframework.batch.item.ItemStreamException; import org.springframework.batch.item.ReaderNotOpenException; +import org.springframework.batch.item.Skippable; +import org.springframework.batch.item.xml.stax.DefaultFragmentEventReader; +import org.springframework.batch.item.xml.stax.DefaultTransactionalEventReader; +import org.springframework.batch.item.xml.stax.FragmentEventReader; +import org.springframework.batch.item.xml.stax.TransactionalEventReader; import org.springframework.beans.factory.InitializingBean; import org.springframework.core.io.Resource; import org.springframework.dao.DataAccessResourceFailureException; @@ -246,7 +246,7 @@ public class StaxEventItemReader extends ExecutionContextUserSupport implements * counter, keeping track of the current position, so multiple threads * cannot be accommodated. * - * @see org.springframework.batch.item.reader.AbstractItemReader#mark() + * @see org.springframework.batch.item.AbstractItemReader#mark() */ public void mark() { lastCommitPointRecordCount = currentRecordCount; diff --git a/spring-batch-infrastructure/src/main/java/org/springframework/batch/io/xml/StaxEventItemWriter.java b/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/xml/StaxEventItemWriter.java similarity index 98% rename from spring-batch-infrastructure/src/main/java/org/springframework/batch/io/xml/StaxEventItemWriter.java rename to spring-batch-infrastructure/src/main/java/org/springframework/batch/item/xml/StaxEventItemWriter.java index b2ff71d7c..555890d95 100644 --- a/spring-batch-infrastructure/src/main/java/org/springframework/batch/io/xml/StaxEventItemWriter.java +++ b/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/xml/StaxEventItemWriter.java @@ -1,4 +1,4 @@ -package org.springframework.batch.io.xml; +package org.springframework.batch.item.xml; import java.io.File; import java.io.FileOutputStream; @@ -15,14 +15,14 @@ import javax.xml.stream.XMLEventWriter; import javax.xml.stream.XMLOutputFactory; import javax.xml.stream.XMLStreamException; -import org.springframework.batch.io.support.FileUtils; -import org.springframework.batch.io.xml.stax.NoStartEndDocumentStreamWriter; import org.springframework.batch.item.ClearFailedException; import org.springframework.batch.item.ExecutionContext; import org.springframework.batch.item.ExecutionContextUserSupport; import org.springframework.batch.item.FlushFailedException; import org.springframework.batch.item.ItemStream; import org.springframework.batch.item.ItemWriter; +import org.springframework.batch.item.support.FileUtils; +import org.springframework.batch.item.xml.stax.NoStartEndDocumentStreamWriter; import org.springframework.beans.factory.InitializingBean; import org.springframework.core.io.Resource; import org.springframework.dao.DataAccessResourceFailureException; diff --git a/spring-batch-infrastructure/src/main/java/org/springframework/batch/io/xml/oxm/MarshallingEventWriterSerializer.java b/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/xml/oxm/MarshallingEventWriterSerializer.java similarity index 89% rename from spring-batch-infrastructure/src/main/java/org/springframework/batch/io/xml/oxm/MarshallingEventWriterSerializer.java rename to spring-batch-infrastructure/src/main/java/org/springframework/batch/item/xml/oxm/MarshallingEventWriterSerializer.java index ea5790e03..fa6a9d74f 100644 --- a/spring-batch-infrastructure/src/main/java/org/springframework/batch/io/xml/oxm/MarshallingEventWriterSerializer.java +++ b/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/xml/oxm/MarshallingEventWriterSerializer.java @@ -1,11 +1,11 @@ -package org.springframework.batch.io.xml.oxm; +package org.springframework.batch.item.xml.oxm; import java.io.IOException; import javax.xml.stream.XMLEventWriter; import javax.xml.transform.Result; -import org.springframework.batch.io.xml.EventWriterSerializer; +import org.springframework.batch.item.xml.EventWriterSerializer; import org.springframework.dao.DataAccessResourceFailureException; import org.springframework.oxm.Marshaller; import org.springframework.xml.transform.StaxResult; diff --git a/spring-batch-infrastructure/src/main/java/org/springframework/batch/io/xml/oxm/UnmarshallingEventReaderDeserializer.java b/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/xml/oxm/UnmarshallingEventReaderDeserializer.java similarity index 89% rename from spring-batch-infrastructure/src/main/java/org/springframework/batch/io/xml/oxm/UnmarshallingEventReaderDeserializer.java rename to spring-batch-infrastructure/src/main/java/org/springframework/batch/item/xml/oxm/UnmarshallingEventReaderDeserializer.java index 1301496d2..53f66e8ef 100644 --- a/spring-batch-infrastructure/src/main/java/org/springframework/batch/io/xml/oxm/UnmarshallingEventReaderDeserializer.java +++ b/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/xml/oxm/UnmarshallingEventReaderDeserializer.java @@ -1,10 +1,10 @@ -package org.springframework.batch.io.xml.oxm; +package org.springframework.batch.item.xml.oxm; import java.io.IOException; import javax.xml.stream.XMLEventReader; -import org.springframework.batch.io.xml.EventReaderDeserializer; +import org.springframework.batch.item.xml.EventReaderDeserializer; import org.springframework.dao.DataAccessResourceFailureException; import org.springframework.oxm.Unmarshaller; import org.springframework.util.Assert; diff --git a/spring-batch-infrastructure/src/main/java/org/springframework/batch/io/xml/package.html b/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/xml/package.html similarity index 100% rename from spring-batch-infrastructure/src/main/java/org/springframework/batch/io/xml/package.html rename to spring-batch-infrastructure/src/main/java/org/springframework/batch/item/xml/package.html diff --git a/spring-batch-infrastructure/src/main/java/org/springframework/batch/io/xml/stax/AbstractEventReaderWrapper.java b/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/xml/stax/AbstractEventReaderWrapper.java similarity index 96% rename from spring-batch-infrastructure/src/main/java/org/springframework/batch/io/xml/stax/AbstractEventReaderWrapper.java rename to spring-batch-infrastructure/src/main/java/org/springframework/batch/item/xml/stax/AbstractEventReaderWrapper.java index a87086f56..4eb3b6eee 100644 --- a/spring-batch-infrastructure/src/main/java/org/springframework/batch/io/xml/stax/AbstractEventReaderWrapper.java +++ b/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/xml/stax/AbstractEventReaderWrapper.java @@ -1,4 +1,4 @@ -package org.springframework.batch.io.xml.stax; +package org.springframework.batch.item.xml.stax; import javax.xml.stream.XMLEventReader; import javax.xml.stream.XMLStreamException; diff --git a/spring-batch-infrastructure/src/main/java/org/springframework/batch/io/xml/stax/AbstractEventWriterWrapper.java b/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/xml/stax/AbstractEventWriterWrapper.java similarity index 97% rename from spring-batch-infrastructure/src/main/java/org/springframework/batch/io/xml/stax/AbstractEventWriterWrapper.java rename to spring-batch-infrastructure/src/main/java/org/springframework/batch/item/xml/stax/AbstractEventWriterWrapper.java index a690e37b1..18a40c616 100644 --- a/spring-batch-infrastructure/src/main/java/org/springframework/batch/io/xml/stax/AbstractEventWriterWrapper.java +++ b/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/xml/stax/AbstractEventWriterWrapper.java @@ -1,4 +1,4 @@ -package org.springframework.batch.io.xml.stax; +package org.springframework.batch.item.xml.stax; import javax.xml.namespace.NamespaceContext; import javax.xml.stream.XMLEventReader; diff --git a/spring-batch-infrastructure/src/main/java/org/springframework/batch/io/xml/stax/DefaultFragmentEventReader.java b/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/xml/stax/DefaultFragmentEventReader.java similarity index 99% rename from spring-batch-infrastructure/src/main/java/org/springframework/batch/io/xml/stax/DefaultFragmentEventReader.java rename to spring-batch-infrastructure/src/main/java/org/springframework/batch/item/xml/stax/DefaultFragmentEventReader.java index 43e43dbf8..698ac3275 100644 --- a/spring-batch-infrastructure/src/main/java/org/springframework/batch/io/xml/stax/DefaultFragmentEventReader.java +++ b/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/xml/stax/DefaultFragmentEventReader.java @@ -1,4 +1,4 @@ -package org.springframework.batch.io.xml.stax; +package org.springframework.batch.item.xml.stax; import java.util.NoSuchElementException; diff --git a/spring-batch-infrastructure/src/main/java/org/springframework/batch/io/xml/stax/DefaultTransactionalEventReader.java b/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/xml/stax/DefaultTransactionalEventReader.java similarity index 97% rename from spring-batch-infrastructure/src/main/java/org/springframework/batch/io/xml/stax/DefaultTransactionalEventReader.java rename to spring-batch-infrastructure/src/main/java/org/springframework/batch/item/xml/stax/DefaultTransactionalEventReader.java index fb5aed660..4c9c83b1a 100644 --- a/spring-batch-infrastructure/src/main/java/org/springframework/batch/io/xml/stax/DefaultTransactionalEventReader.java +++ b/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/xml/stax/DefaultTransactionalEventReader.java @@ -1,4 +1,4 @@ -package org.springframework.batch.io.xml.stax; +package org.springframework.batch.item.xml.stax; import java.util.NoSuchElementException; diff --git a/spring-batch-infrastructure/src/main/java/org/springframework/batch/io/xml/stax/EventSequence.java b/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/xml/stax/EventSequence.java similarity index 97% rename from spring-batch-infrastructure/src/main/java/org/springframework/batch/io/xml/stax/EventSequence.java rename to spring-batch-infrastructure/src/main/java/org/springframework/batch/item/xml/stax/EventSequence.java index bd8d6d4e7..e31e35a31 100644 --- a/spring-batch-infrastructure/src/main/java/org/springframework/batch/io/xml/stax/EventSequence.java +++ b/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/xml/stax/EventSequence.java @@ -1,4 +1,4 @@ -package org.springframework.batch.io.xml.stax; +package org.springframework.batch.item.xml.stax; import java.util.ArrayList; import java.util.List; diff --git a/spring-batch-infrastructure/src/main/java/org/springframework/batch/io/xml/stax/FragmentEventReader.java b/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/xml/stax/FragmentEventReader.java similarity index 94% rename from spring-batch-infrastructure/src/main/java/org/springframework/batch/io/xml/stax/FragmentEventReader.java rename to spring-batch-infrastructure/src/main/java/org/springframework/batch/item/xml/stax/FragmentEventReader.java index 6607d3762..414d64cdf 100644 --- a/spring-batch-infrastructure/src/main/java/org/springframework/batch/io/xml/stax/FragmentEventReader.java +++ b/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/xml/stax/FragmentEventReader.java @@ -1,4 +1,4 @@ -package org.springframework.batch.io.xml.stax; +package org.springframework.batch.item.xml.stax; import javax.xml.stream.XMLEventReader; diff --git a/spring-batch-infrastructure/src/main/java/org/springframework/batch/io/xml/stax/NoStartEndDocumentStreamWriter.java b/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/xml/stax/NoStartEndDocumentStreamWriter.java similarity index 93% rename from spring-batch-infrastructure/src/main/java/org/springframework/batch/io/xml/stax/NoStartEndDocumentStreamWriter.java rename to spring-batch-infrastructure/src/main/java/org/springframework/batch/item/xml/stax/NoStartEndDocumentStreamWriter.java index d4f8bc298..80353b8e8 100644 --- a/spring-batch-infrastructure/src/main/java/org/springframework/batch/io/xml/stax/NoStartEndDocumentStreamWriter.java +++ b/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/xml/stax/NoStartEndDocumentStreamWriter.java @@ -1,4 +1,4 @@ -package org.springframework.batch.io.xml.stax; +package org.springframework.batch.item.xml.stax; import javax.xml.stream.XMLEventWriter; import javax.xml.stream.XMLStreamException; diff --git a/spring-batch-infrastructure/src/main/java/org/springframework/batch/io/xml/stax/TransactionalEventReader.java b/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/xml/stax/TransactionalEventReader.java similarity index 88% rename from spring-batch-infrastructure/src/main/java/org/springframework/batch/io/xml/stax/TransactionalEventReader.java rename to spring-batch-infrastructure/src/main/java/org/springframework/batch/item/xml/stax/TransactionalEventReader.java index 06da7b475..4117b8751 100644 --- a/spring-batch-infrastructure/src/main/java/org/springframework/batch/io/xml/stax/TransactionalEventReader.java +++ b/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/xml/stax/TransactionalEventReader.java @@ -1,4 +1,4 @@ -package org.springframework.batch.io.xml.stax; +package org.springframework.batch.item.xml.stax; import javax.xml.stream.XMLEventReader; diff --git a/spring-batch-infrastructure/src/test/java/org/springframework/batch/item/ItemProviderTests.java b/spring-batch-infrastructure/src/test/java/org/springframework/batch/item/ItemProviderTests.java index ea6cc4182..cb6597cd0 100644 --- a/spring-batch-infrastructure/src/test/java/org/springframework/batch/item/ItemProviderTests.java +++ b/spring-batch-infrastructure/src/test/java/org/springframework/batch/item/ItemProviderTests.java @@ -18,7 +18,6 @@ package org.springframework.batch.item; import junit.framework.TestCase; -import org.springframework.batch.item.reader.AbstractItemReader; public class ItemProviderTests extends TestCase { diff --git a/spring-batch-infrastructure/src/test/java/org/springframework/batch/io/support/AbstractDataSourceItemReaderIntegrationTests.java b/spring-batch-infrastructure/src/test/java/org/springframework/batch/item/database/AbstractDataSourceItemReaderIntegrationTests.java similarity index 96% rename from spring-batch-infrastructure/src/test/java/org/springframework/batch/io/support/AbstractDataSourceItemReaderIntegrationTests.java rename to spring-batch-infrastructure/src/test/java/org/springframework/batch/item/database/AbstractDataSourceItemReaderIntegrationTests.java index 72d4469f5..8a3fa4c48 100644 --- a/spring-batch-infrastructure/src/test/java/org/springframework/batch/io/support/AbstractDataSourceItemReaderIntegrationTests.java +++ b/spring-batch-infrastructure/src/test/java/org/springframework/batch/item/database/AbstractDataSourceItemReaderIntegrationTests.java @@ -1,10 +1,10 @@ -package org.springframework.batch.io.support; +package org.springframework.batch.item.database; -import org.springframework.batch.io.Skippable; import org.springframework.batch.io.sample.domain.Foo; import org.springframework.batch.item.ExecutionContext; import org.springframework.batch.item.ItemReader; import org.springframework.batch.item.ItemStream; +import org.springframework.batch.item.Skippable; import org.springframework.beans.factory.InitializingBean; import org.springframework.test.AbstractTransactionalDataSourceSpringContextTests; import org.springframework.util.Assert; @@ -28,7 +28,7 @@ public abstract class AbstractDataSourceItemReaderIntegrationTests extends protected abstract ItemReader createItemReader() throws Exception; protected String[] getConfigLocations() { - return new String[] { "org/springframework/batch/io/sql/data-source-context.xml" }; + return new String[] { "org/springframework/batch/item/database/data-source-context.xml" }; } /* diff --git a/spring-batch-infrastructure/src/test/java/org/springframework/batch/io/sql/AbstractJdbcItemReaderIntegrationTests.java b/spring-batch-infrastructure/src/test/java/org/springframework/batch/item/database/AbstractJdbcItemReaderIntegrationTests.java similarity index 96% rename from spring-batch-infrastructure/src/test/java/org/springframework/batch/io/sql/AbstractJdbcItemReaderIntegrationTests.java rename to spring-batch-infrastructure/src/test/java/org/springframework/batch/item/database/AbstractJdbcItemReaderIntegrationTests.java index 44fa56112..378ec1539 100644 --- a/spring-batch-infrastructure/src/test/java/org/springframework/batch/io/sql/AbstractJdbcItemReaderIntegrationTests.java +++ b/spring-batch-infrastructure/src/test/java/org/springframework/batch/item/database/AbstractJdbcItemReaderIntegrationTests.java @@ -1,4 +1,4 @@ -package org.springframework.batch.io.sql; +package org.springframework.batch.item.database; import org.springframework.batch.io.sample.domain.Foo; import org.springframework.batch.item.ExecutionContext; @@ -27,7 +27,7 @@ public abstract class AbstractJdbcItemReaderIntegrationTests extends AbstractTra protected abstract ItemReader createItemReader() throws Exception; protected String[] getConfigLocations(){ - return new String[] { "org/springframework/batch/io/sql/data-source-context.xml"}; + return new String[] { "org/springframework/batch/item/database/data-source-context.xml"}; } protected void onSetUp()throws Exception{ diff --git a/spring-batch-infrastructure/src/test/java/org/springframework/batch/io/support/BatchSqlUpdateItemWriterTests.java b/spring-batch-infrastructure/src/test/java/org/springframework/batch/item/database/BatchSqlUpdateItemWriterTests.java similarity index 90% rename from spring-batch-infrastructure/src/test/java/org/springframework/batch/io/support/BatchSqlUpdateItemWriterTests.java rename to spring-batch-infrastructure/src/test/java/org/springframework/batch/item/database/BatchSqlUpdateItemWriterTests.java index 976a999ff..0db3c6740 100644 --- a/spring-batch-infrastructure/src/test/java/org/springframework/batch/io/support/BatchSqlUpdateItemWriterTests.java +++ b/spring-batch-infrastructure/src/test/java/org/springframework/batch/item/database/BatchSqlUpdateItemWriterTests.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package org.springframework.batch.io.support; +package org.springframework.batch.item.database; import java.sql.PreparedStatement; import java.sql.SQLException; @@ -27,6 +27,8 @@ import java.util.Map; import junit.framework.TestCase; import org.easymock.MockControl; +import org.springframework.batch.item.database.BatchSqlUpdateItemWriter; +import org.springframework.batch.item.database.ItemPreparedStatementSetter; import org.springframework.batch.repeat.RepeatContext; import org.springframework.batch.repeat.context.RepeatContextSupport; import org.springframework.batch.repeat.synch.RepeatSynchronizationManager; @@ -98,7 +100,7 @@ public class BatchSqlUpdateItemWriterTests extends TestCase { /** * Test method for - * {@link org.springframework.batch.io.support.BatchSqlUpdateItemWriter#afterPropertiesSet()}. + * {@link org.springframework.batch.item.database.BatchSqlUpdateItemWriter#afterPropertiesSet()}. * @throws Exception */ public void testAfterPropertiesSet() throws Exception { @@ -114,7 +116,7 @@ public class BatchSqlUpdateItemWriterTests extends TestCase { /** * Test method for - * {@link org.springframework.batch.io.support.BatchSqlUpdateItemWriter#write(java.lang.Object)}. + * {@link org.springframework.batch.item.database.BatchSqlUpdateItemWriter#write(java.lang.Object)}. * @throws Exception */ public void testWrite() throws Exception { @@ -126,7 +128,7 @@ public class BatchSqlUpdateItemWriterTests extends TestCase { /** * Test method for - * {@link org.springframework.batch.io.support.BatchSqlUpdateItemWriter#clear()}. + * {@link org.springframework.batch.item.database.BatchSqlUpdateItemWriter#clear()}. */ public void testClear() { assertTrue(TransactionSynchronizationManager.hasResource(BatchSqlUpdateItemWriter.ITEMS_PROCESSED)); @@ -136,7 +138,7 @@ public class BatchSqlUpdateItemWriterTests extends TestCase { /** * Test method for - * {@link org.springframework.batch.io.support.BatchSqlUpdateItemWriter#flush()}. + * {@link org.springframework.batch.item.database.BatchSqlUpdateItemWriter#flush()}. */ public void testFlush() { assertTrue(TransactionSynchronizationManager.hasResource(BatchSqlUpdateItemWriter.ITEMS_PROCESSED)); @@ -148,7 +150,7 @@ public class BatchSqlUpdateItemWriterTests extends TestCase { /** * Test method for - * {@link org.springframework.batch.io.support.BatchSqlUpdateItemWriter#flush()}. + * {@link org.springframework.batch.item.database.BatchSqlUpdateItemWriter#flush()}. * @throws Exception */ public void testWriteAndFlush() throws Exception { diff --git a/spring-batch-infrastructure/src/test/java/org/springframework/batch/io/driving/CompositeKeyFooDao.java b/spring-batch-infrastructure/src/test/java/org/springframework/batch/item/database/CompositeKeyFooDao.java similarity index 97% rename from spring-batch-infrastructure/src/test/java/org/springframework/batch/io/driving/CompositeKeyFooDao.java rename to spring-batch-infrastructure/src/test/java/org/springframework/batch/item/database/CompositeKeyFooDao.java index ac938f4ea..429aa4df5 100644 --- a/spring-batch-infrastructure/src/test/java/org/springframework/batch/io/driving/CompositeKeyFooDao.java +++ b/spring-batch-infrastructure/src/test/java/org/springframework/batch/item/database/CompositeKeyFooDao.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package org.springframework.batch.io.driving; +package org.springframework.batch.item.database; import java.sql.ResultSet; import java.sql.SQLException; diff --git a/spring-batch-infrastructure/src/test/java/org/springframework/batch/io/driving/DrivingQueryItemReaderTests.java b/spring-batch-infrastructure/src/test/java/org/springframework/batch/item/database/DrivingQueryItemReaderTests.java similarity index 96% rename from spring-batch-infrastructure/src/test/java/org/springframework/batch/io/driving/DrivingQueryItemReaderTests.java rename to spring-batch-infrastructure/src/test/java/org/springframework/batch/item/database/DrivingQueryItemReaderTests.java index 1d168f251..9fd37f1d7 100644 --- a/spring-batch-infrastructure/src/test/java/org/springframework/batch/io/driving/DrivingQueryItemReaderTests.java +++ b/spring-batch-infrastructure/src/test/java/org/springframework/batch/item/database/DrivingQueryItemReaderTests.java @@ -1,4 +1,4 @@ -package org.springframework.batch.io.driving; +package org.springframework.batch.item.database; import java.util.ArrayList; import java.util.List; @@ -11,6 +11,8 @@ import org.springframework.batch.item.ExecutionContext; import org.springframework.batch.item.ItemReader; import org.springframework.batch.item.ItemStream; import org.springframework.batch.item.NoWorkFoundException; +import org.springframework.batch.item.database.DrivingQueryItemReader; +import org.springframework.batch.item.database.KeyGenerator; import org.springframework.beans.factory.InitializingBean; import org.springframework.transaction.support.TransactionSynchronizationManager; import org.springframework.util.Assert; diff --git a/spring-batch-infrastructure/src/test/java/org/springframework/batch/io/driving/FooDao.java b/spring-batch-infrastructure/src/test/java/org/springframework/batch/item/database/FooDao.java similarity index 94% rename from spring-batch-infrastructure/src/test/java/org/springframework/batch/io/driving/FooDao.java rename to spring-batch-infrastructure/src/test/java/org/springframework/batch/item/database/FooDao.java index 8fe633d70..e90770d85 100644 --- a/spring-batch-infrastructure/src/test/java/org/springframework/batch/io/driving/FooDao.java +++ b/spring-batch-infrastructure/src/test/java/org/springframework/batch/item/database/FooDao.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package org.springframework.batch.io.driving; +package org.springframework.batch.item.database; import org.springframework.batch.io.sample.domain.Foo; import org.springframework.jdbc.core.JdbcTemplate; diff --git a/spring-batch-infrastructure/src/test/java/org/springframework/batch/io/driving/FooInputSource.java b/spring-batch-infrastructure/src/test/java/org/springframework/batch/item/database/FooInputSource.java similarity index 93% rename from spring-batch-infrastructure/src/test/java/org/springframework/batch/io/driving/FooInputSource.java rename to spring-batch-infrastructure/src/test/java/org/springframework/batch/item/database/FooInputSource.java index 7c3b1e113..04da4cd70 100644 --- a/spring-batch-infrastructure/src/test/java/org/springframework/batch/io/driving/FooInputSource.java +++ b/spring-batch-infrastructure/src/test/java/org/springframework/batch/item/database/FooInputSource.java @@ -1,8 +1,9 @@ -package org.springframework.batch.io.driving; +package org.springframework.batch.item.database; import org.springframework.batch.item.ExecutionContext; import org.springframework.batch.item.ItemReader; import org.springframework.batch.item.ItemStream; +import org.springframework.batch.item.database.DrivingQueryItemReader; import org.springframework.beans.factory.DisposableBean; import org.springframework.beans.factory.InitializingBean; import org.springframework.jdbc.core.JdbcTemplate; diff --git a/spring-batch-infrastructure/src/test/java/org/springframework/batch/io/driving/FooRowMapper.java b/spring-batch-infrastructure/src/test/java/org/springframework/batch/item/database/FooRowMapper.java similarity index 89% rename from spring-batch-infrastructure/src/test/java/org/springframework/batch/io/driving/FooRowMapper.java rename to spring-batch-infrastructure/src/test/java/org/springframework/batch/item/database/FooRowMapper.java index 34bd3b767..95d3db0ac 100644 --- a/spring-batch-infrastructure/src/test/java/org/springframework/batch/io/driving/FooRowMapper.java +++ b/spring-batch-infrastructure/src/test/java/org/springframework/batch/item/database/FooRowMapper.java @@ -1,4 +1,4 @@ -package org.springframework.batch.io.driving; +package org.springframework.batch.item.database; import java.sql.ResultSet; import java.sql.SQLException; diff --git a/spring-batch-infrastructure/src/test/java/org/springframework/batch/io/support/HibernateAwareItemWriterTests.java b/spring-batch-infrastructure/src/test/java/org/springframework/batch/item/database/HibernateAwareItemWriterTests.java similarity index 85% rename from spring-batch-infrastructure/src/test/java/org/springframework/batch/io/support/HibernateAwareItemWriterTests.java rename to spring-batch-infrastructure/src/test/java/org/springframework/batch/item/database/HibernateAwareItemWriterTests.java index 76436de0c..b3588fa6e 100644 --- a/spring-batch-infrastructure/src/test/java/org/springframework/batch/io/support/HibernateAwareItemWriterTests.java +++ b/spring-batch-infrastructure/src/test/java/org/springframework/batch/item/database/HibernateAwareItemWriterTests.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package org.springframework.batch.io.support; +package org.springframework.batch.item.database; import java.util.ArrayList; import java.util.Iterator; @@ -25,6 +25,7 @@ import junit.framework.TestCase; import org.springframework.batch.item.ClearFailedException; import org.springframework.batch.item.FlushFailedException; import org.springframework.batch.item.ItemWriter; +import org.springframework.batch.item.database.HibernateAwareItemWriter; import org.springframework.batch.repeat.context.RepeatContextSupport; import org.springframework.batch.repeat.synch.RepeatSynchronizationManager; import org.springframework.dao.DataAccessException; @@ -93,7 +94,7 @@ public class HibernateAwareItemWriterTests extends TestCase { /** * Test method for - * {@link org.springframework.batch.io.support.HibernateAwareItemWriter#initDao()}. + * {@link org.springframework.batch.item.database.HibernateAwareItemWriter#initDao()}. * * @throws Exception */ @@ -111,7 +112,7 @@ public class HibernateAwareItemWriterTests extends TestCase { /** * Test method for - * {@link org.springframework.batch.io.support.HibernateAwareItemWriter#initDao()}. + * {@link org.springframework.batch.item.database.HibernateAwareItemWriter#initDao()}. * * @throws Exception */ @@ -121,7 +122,7 @@ public class HibernateAwareItemWriterTests extends TestCase { /** * Test method for - * {@link org.springframework.batch.io.support.HibernateAwareItemWriter#write(java.lang.Object)}. + * {@link org.springframework.batch.item.database.HibernateAwareItemWriter#write(java.lang.Object)}. * @throws Exception */ public void testWrite() throws Exception { @@ -132,7 +133,7 @@ public class HibernateAwareItemWriterTests extends TestCase { /** * Test method for - * {@link org.springframework.batch.io.support.HibernateAwareItemWriter#write(java.lang.Object)}. + * {@link org.springframework.batch.item.database.HibernateAwareItemWriter#write(java.lang.Object)}. */ public void testFlushWithFailure() throws Exception{ final RuntimeException ex = new RuntimeException("bar"); @@ -151,7 +152,7 @@ public class HibernateAwareItemWriterTests extends TestCase { /** * Test method for - * {@link org.springframework.batch.io.support.HibernateAwareItemWriter#write(java.lang.Object)}. + * {@link org.springframework.batch.item.database.HibernateAwareItemWriter#write(java.lang.Object)}. * @throws Exception */ public void testWriteAndFlushWithFailure() throws Exception { @@ -183,7 +184,7 @@ public class HibernateAwareItemWriterTests extends TestCase { /** * Test method for - * {@link org.springframework.batch.io.support.HibernateAwareItemWriter#close(org.springframework.batch.repeat.RepeatContext)}. + * {@link org.springframework.batch.item.database.HibernateAwareItemWriter#close(org.springframework.batch.repeat.RepeatContext)}. */ public void testFlush() throws Exception{ writer.flush(); @@ -195,7 +196,7 @@ public class HibernateAwareItemWriterTests extends TestCase { /** * Test method for - * {@link org.springframework.batch.io.support.HibernateAwareItemWriter#close(org.springframework.batch.repeat.RepeatContext)}. + * {@link org.springframework.batch.item.database.HibernateAwareItemWriter#close(org.springframework.batch.repeat.RepeatContext)}. */ public void testClear() throws Exception{ writer.clear(); diff --git a/spring-batch-infrastructure/src/test/java/org/springframework/batch/io/cursor/HibernateCursorItemReaderIntegrationTests.java b/spring-batch-infrastructure/src/test/java/org/springframework/batch/item/database/HibernateCursorItemReaderIntegrationTests.java similarity index 93% rename from spring-batch-infrastructure/src/test/java/org/springframework/batch/io/cursor/HibernateCursorItemReaderIntegrationTests.java rename to spring-batch-infrastructure/src/test/java/org/springframework/batch/item/database/HibernateCursorItemReaderIntegrationTests.java index 964f883c6..d652bb842 100644 --- a/spring-batch-infrastructure/src/test/java/org/springframework/batch/io/cursor/HibernateCursorItemReaderIntegrationTests.java +++ b/spring-batch-infrastructure/src/test/java/org/springframework/batch/item/database/HibernateCursorItemReaderIntegrationTests.java @@ -1,10 +1,10 @@ -package org.springframework.batch.io.cursor; +package org.springframework.batch.item.database; import org.hibernate.SessionFactory; import org.hibernate.StatelessSession; -import org.springframework.batch.io.support.AbstractDataSourceItemReaderIntegrationTests; import org.springframework.batch.item.ExecutionContext; import org.springframework.batch.item.ItemReader; +import org.springframework.batch.item.database.HibernateCursorItemReader; import org.springframework.core.io.ClassPathResource; import org.springframework.core.io.Resource; import org.springframework.orm.hibernate3.LocalSessionFactoryBean; diff --git a/spring-batch-infrastructure/src/test/java/org/springframework/batch/io/cursor/HibernateCursorItemReaderStatefulIntegrationTests.java b/spring-batch-infrastructure/src/test/java/org/springframework/batch/item/database/HibernateCursorItemReaderStatefulIntegrationTests.java similarity index 73% rename from spring-batch-infrastructure/src/test/java/org/springframework/batch/io/cursor/HibernateCursorItemReaderStatefulIntegrationTests.java rename to spring-batch-infrastructure/src/test/java/org/springframework/batch/item/database/HibernateCursorItemReaderStatefulIntegrationTests.java index 64f07c19d..aadef26ad 100644 --- a/spring-batch-infrastructure/src/test/java/org/springframework/batch/io/cursor/HibernateCursorItemReaderStatefulIntegrationTests.java +++ b/spring-batch-infrastructure/src/test/java/org/springframework/batch/item/database/HibernateCursorItemReaderStatefulIntegrationTests.java @@ -1,6 +1,7 @@ -package org.springframework.batch.io.cursor; +package org.springframework.batch.item.database; import org.hibernate.Session; +import org.springframework.batch.item.database.HibernateCursorItemReader; /** * Tests for {@link HibernateCursorItemReader} using standard hibernate {@link Session}. diff --git a/spring-batch-infrastructure/src/test/java/org/springframework/batch/io/driving/IbatisItemReaderIntegrationTests.java b/spring-batch-infrastructure/src/test/java/org/springframework/batch/item/database/IbatisItemReaderIntegrationTests.java similarity index 86% rename from spring-batch-infrastructure/src/test/java/org/springframework/batch/io/driving/IbatisItemReaderIntegrationTests.java rename to spring-batch-infrastructure/src/test/java/org/springframework/batch/item/database/IbatisItemReaderIntegrationTests.java index eb5ac8d5a..08136dd85 100644 --- a/spring-batch-infrastructure/src/test/java/org/springframework/batch/io/driving/IbatisItemReaderIntegrationTests.java +++ b/spring-batch-infrastructure/src/test/java/org/springframework/batch/item/database/IbatisItemReaderIntegrationTests.java @@ -1,8 +1,8 @@ -package org.springframework.batch.io.driving; +package org.springframework.batch.item.database; -import org.springframework.batch.io.driving.support.IbatisKeyGenerator; -import org.springframework.batch.io.support.AbstractDataSourceItemReaderIntegrationTests; import org.springframework.batch.item.ItemReader; +import org.springframework.batch.item.database.IbatisDrivingQueryItemReader; +import org.springframework.batch.item.database.support.IbatisKeyGenerator; import org.springframework.core.io.ClassPathResource; import org.springframework.orm.ibatis.SqlMapClientFactoryBean; diff --git a/spring-batch-infrastructure/src/test/java/org/springframework/batch/io/cursor/JdbcCursorItemReaderIntegrationTests.java b/spring-batch-infrastructure/src/test/java/org/springframework/batch/item/database/JdbcCursorItemReaderIntegrationTests.java similarity index 79% rename from spring-batch-infrastructure/src/test/java/org/springframework/batch/io/cursor/JdbcCursorItemReaderIntegrationTests.java rename to spring-batch-infrastructure/src/test/java/org/springframework/batch/item/database/JdbcCursorItemReaderIntegrationTests.java index 70d81c5e9..68e6bcc47 100644 --- a/spring-batch-infrastructure/src/test/java/org/springframework/batch/io/cursor/JdbcCursorItemReaderIntegrationTests.java +++ b/spring-batch-infrastructure/src/test/java/org/springframework/batch/item/database/JdbcCursorItemReaderIntegrationTests.java @@ -1,8 +1,7 @@ -package org.springframework.batch.io.cursor; +package org.springframework.batch.item.database; -import org.springframework.batch.io.driving.FooRowMapper; -import org.springframework.batch.io.support.AbstractDataSourceItemReaderIntegrationTests; import org.springframework.batch.item.ItemReader; +import org.springframework.batch.item.database.JdbcCursorItemReader; /** * Tests for {@link JdbcCursorItemReader} diff --git a/spring-batch-infrastructure/src/test/java/org/springframework/batch/io/driving/MultipleColumnJdbcDrivingQueryItemReaderIntegrationTests.java b/spring-batch-infrastructure/src/test/java/org/springframework/batch/item/database/MultipleColumnJdbcDrivingQueryItemReaderIntegrationTests.java similarity index 87% rename from spring-batch-infrastructure/src/test/java/org/springframework/batch/io/driving/MultipleColumnJdbcDrivingQueryItemReaderIntegrationTests.java rename to spring-batch-infrastructure/src/test/java/org/springframework/batch/item/database/MultipleColumnJdbcDrivingQueryItemReaderIntegrationTests.java index feae7bd22..d31d73b0e 100644 --- a/spring-batch-infrastructure/src/test/java/org/springframework/batch/io/driving/MultipleColumnJdbcDrivingQueryItemReaderIntegrationTests.java +++ b/spring-batch-infrastructure/src/test/java/org/springframework/batch/item/database/MultipleColumnJdbcDrivingQueryItemReaderIntegrationTests.java @@ -13,11 +13,11 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package org.springframework.batch.io.driving; +package org.springframework.batch.item.database; -import org.springframework.batch.io.driving.support.MultipleColumnJdbcKeyGenerator; -import org.springframework.batch.io.sql.AbstractJdbcItemReaderIntegrationTests; import org.springframework.batch.item.ItemReader; +import org.springframework.batch.item.database.DrivingQueryItemReader; +import org.springframework.batch.item.database.support.MultipleColumnJdbcKeyGenerator; /** * @author Lucas Ward diff --git a/spring-batch-infrastructure/src/test/java/org/springframework/batch/io/driving/SingleColumnJdbcDrivingQueryItemReaderIntegrationTests.java b/spring-batch-infrastructure/src/test/java/org/springframework/batch/item/database/SingleColumnJdbcDrivingQueryItemReaderIntegrationTests.java similarity index 78% rename from spring-batch-infrastructure/src/test/java/org/springframework/batch/io/driving/SingleColumnJdbcDrivingQueryItemReaderIntegrationTests.java rename to spring-batch-infrastructure/src/test/java/org/springframework/batch/item/database/SingleColumnJdbcDrivingQueryItemReaderIntegrationTests.java index 7559da69f..480a6a26f 100644 --- a/spring-batch-infrastructure/src/test/java/org/springframework/batch/io/driving/SingleColumnJdbcDrivingQueryItemReaderIntegrationTests.java +++ b/spring-batch-infrastructure/src/test/java/org/springframework/batch/item/database/SingleColumnJdbcDrivingQueryItemReaderIntegrationTests.java @@ -1,8 +1,8 @@ -package org.springframework.batch.io.driving; +package org.springframework.batch.item.database; -import org.springframework.batch.io.driving.support.SingleColumnJdbcKeyGenerator; -import org.springframework.batch.io.sql.AbstractJdbcItemReaderIntegrationTests; import org.springframework.batch.item.ItemReader; +import org.springframework.batch.item.database.DrivingQueryItemReader; +import org.springframework.batch.item.database.support.SingleColumnJdbcKeyGenerator; public class SingleColumnJdbcDrivingQueryItemReaderIntegrationTests extends AbstractJdbcItemReaderIntegrationTests { diff --git a/spring-batch-infrastructure/src/test/java/org/springframework/batch/io/driving/SingleKeyFooDao.java b/spring-batch-infrastructure/src/test/java/org/springframework/batch/item/database/SingleKeyFooDao.java similarity index 93% rename from spring-batch-infrastructure/src/test/java/org/springframework/batch/io/driving/SingleKeyFooDao.java rename to spring-batch-infrastructure/src/test/java/org/springframework/batch/item/database/SingleKeyFooDao.java index a9d85c360..f3d2bcba3 100644 --- a/spring-batch-infrastructure/src/test/java/org/springframework/batch/io/driving/SingleKeyFooDao.java +++ b/spring-batch-infrastructure/src/test/java/org/springframework/batch/item/database/SingleKeyFooDao.java @@ -1,4 +1,4 @@ -package org.springframework.batch.io.driving; +package org.springframework.batch.item.database; import java.sql.ResultSet; import java.sql.SQLException; diff --git a/spring-batch-infrastructure/src/test/java/org/springframework/batch/io/driving/support/ColumnMapExecutionContextRowMapperTests.java b/spring-batch-infrastructure/src/test/java/org/springframework/batch/item/database/support/ColumnMapExecutionContextRowMapperTests.java similarity index 94% rename from spring-batch-infrastructure/src/test/java/org/springframework/batch/io/driving/support/ColumnMapExecutionContextRowMapperTests.java rename to spring-batch-infrastructure/src/test/java/org/springframework/batch/item/database/support/ColumnMapExecutionContextRowMapperTests.java index c967979a2..6e3c94f87 100644 --- a/spring-batch-infrastructure/src/test/java/org/springframework/batch/io/driving/support/ColumnMapExecutionContextRowMapperTests.java +++ b/spring-batch-infrastructure/src/test/java/org/springframework/batch/item/database/support/ColumnMapExecutionContextRowMapperTests.java @@ -1,7 +1,7 @@ /** * */ -package org.springframework.batch.io.driving.support; +package org.springframework.batch.item.database.support; import java.sql.PreparedStatement; import java.util.HashMap; @@ -12,6 +12,7 @@ import junit.framework.TestCase; import org.easymock.MockControl; import org.springframework.batch.item.ExecutionContext; +import org.springframework.batch.item.database.support.ColumnMapExecutionContextRowMapper; import org.springframework.core.CollectionFactory; import org.springframework.jdbc.core.PreparedStatementSetter; diff --git a/spring-batch-infrastructure/src/test/java/org/springframework/batch/io/driving/support/MultipleColumnJdbcKeyGeneratorIntegrationTests.java b/spring-batch-infrastructure/src/test/java/org/springframework/batch/item/database/support/MultipleColumnJdbcKeyGeneratorIntegrationTests.java similarity index 88% rename from spring-batch-infrastructure/src/test/java/org/springframework/batch/io/driving/support/MultipleColumnJdbcKeyGeneratorIntegrationTests.java rename to spring-batch-infrastructure/src/test/java/org/springframework/batch/item/database/support/MultipleColumnJdbcKeyGeneratorIntegrationTests.java index 539cdb3d1..7a3101d1d 100644 --- a/spring-batch-infrastructure/src/test/java/org/springframework/batch/io/driving/support/MultipleColumnJdbcKeyGeneratorIntegrationTests.java +++ b/spring-batch-infrastructure/src/test/java/org/springframework/batch/item/database/support/MultipleColumnJdbcKeyGeneratorIntegrationTests.java @@ -1,7 +1,7 @@ /** * */ -package org.springframework.batch.io.driving.support; +package org.springframework.batch.item.database.support; import java.sql.ResultSet; import java.sql.SQLException; @@ -12,6 +12,9 @@ import java.util.Properties; import java.util.Map.Entry; import org.springframework.batch.item.ExecutionContext; +import org.springframework.batch.item.database.support.ColumnMapExecutionContextRowMapper; +import org.springframework.batch.item.database.support.ExecutionContextRowMapper; +import org.springframework.batch.item.database.support.MultipleColumnJdbcKeyGenerator; import org.springframework.core.CollectionFactory; import org.springframework.jdbc.core.PreparedStatementSetter; import org.springframework.test.AbstractTransactionalDataSourceSpringContextTests; @@ -27,7 +30,7 @@ public class MultipleColumnJdbcKeyGeneratorIntegrationTests extends AbstractTran ExecutionContext executionContext; protected String[] getConfigLocations(){ - return new String[] { "org/springframework/batch/io/sql/data-source-context.xml"}; + return new String[] { "org/springframework/batch/item/database/data-source-context.xml"}; } protected void onSetUpBeforeTransaction() throws Exception { diff --git a/spring-batch-infrastructure/src/test/java/org/springframework/batch/io/driving/support/SingleColumnJdbcKeyGeneratorIntegrationTests.java b/spring-batch-infrastructure/src/test/java/org/springframework/batch/item/database/support/SingleColumnJdbcKeyGeneratorIntegrationTests.java similarity index 88% rename from spring-batch-infrastructure/src/test/java/org/springframework/batch/io/driving/support/SingleColumnJdbcKeyGeneratorIntegrationTests.java rename to spring-batch-infrastructure/src/test/java/org/springframework/batch/item/database/support/SingleColumnJdbcKeyGeneratorIntegrationTests.java index 625841da7..cabfad7a8 100644 --- a/spring-batch-infrastructure/src/test/java/org/springframework/batch/io/driving/support/SingleColumnJdbcKeyGeneratorIntegrationTests.java +++ b/spring-batch-infrastructure/src/test/java/org/springframework/batch/item/database/support/SingleColumnJdbcKeyGeneratorIntegrationTests.java @@ -1,8 +1,9 @@ -package org.springframework.batch.io.driving.support; +package org.springframework.batch.item.database.support; import java.util.List; import org.springframework.batch.item.ExecutionContext; +import org.springframework.batch.item.database.support.SingleColumnJdbcKeyGenerator; import org.springframework.test.AbstractTransactionalDataSourceSpringContextTests; /** @@ -17,7 +18,7 @@ public class SingleColumnJdbcKeyGeneratorIntegrationTests extends AbstractTransa ExecutionContext executionContext; protected String[] getConfigLocations(){ - return new String[] { "org/springframework/batch/io/sql/data-source-context.xml"}; + return new String[] { "org/springframework/batch/item/database/data-source-context.xml"}; } diff --git a/spring-batch-infrastructure/src/test/java/org/springframework/batch/io/file/FieldSetTests.java b/spring-batch-infrastructure/src/test/java/org/springframework/batch/item/file/FieldSetTests.java similarity index 98% rename from spring-batch-infrastructure/src/test/java/org/springframework/batch/io/file/FieldSetTests.java rename to spring-batch-infrastructure/src/test/java/org/springframework/batch/item/file/FieldSetTests.java index 4236d475b..596ecc04b 100644 --- a/spring-batch-infrastructure/src/test/java/org/springframework/batch/io/file/FieldSetTests.java +++ b/spring-batch-infrastructure/src/test/java/org/springframework/batch/item/file/FieldSetTests.java @@ -14,15 +14,15 @@ * limitations under the License. */ -package org.springframework.batch.io.file; +package org.springframework.batch.item.file; import java.math.BigDecimal; import java.text.ParseException; import junit.framework.TestCase; -import org.springframework.batch.io.file.mapping.DefaultFieldSet; -import org.springframework.batch.io.file.mapping.FieldSet; +import org.springframework.batch.item.file.mapping.DefaultFieldSet; +import org.springframework.batch.item.file.mapping.FieldSet; public class FieldSetTests extends TestCase { FieldSet fieldSet; diff --git a/spring-batch-infrastructure/src/test/java/org/springframework/batch/io/file/FlatFileItemReaderAdvancedTests.java b/spring-batch-infrastructure/src/test/java/org/springframework/batch/item/file/FlatFileItemReaderAdvancedTests.java similarity index 94% rename from spring-batch-infrastructure/src/test/java/org/springframework/batch/io/file/FlatFileItemReaderAdvancedTests.java rename to spring-batch-infrastructure/src/test/java/org/springframework/batch/item/file/FlatFileItemReaderAdvancedTests.java index c6189fbe4..3276c0481 100644 --- a/spring-batch-infrastructure/src/test/java/org/springframework/batch/io/file/FlatFileItemReaderAdvancedTests.java +++ b/spring-batch-infrastructure/src/test/java/org/springframework/batch/item/file/FlatFileItemReaderAdvancedTests.java @@ -14,17 +14,17 @@ * limitations under the License. */ -package org.springframework.batch.io.file; +package org.springframework.batch.item.file; import java.io.IOException; import junit.framework.TestCase; -import org.springframework.batch.io.file.mapping.DefaultFieldSet; -import org.springframework.batch.io.file.mapping.FieldSet; -import org.springframework.batch.io.file.mapping.FieldSetMapper; -import org.springframework.batch.io.file.transform.LineTokenizer; import org.springframework.batch.item.ExecutionContext; +import org.springframework.batch.item.file.mapping.DefaultFieldSet; +import org.springframework.batch.item.file.mapping.FieldSet; +import org.springframework.batch.item.file.mapping.FieldSetMapper; +import org.springframework.batch.item.file.transform.LineTokenizer; import org.springframework.core.io.ByteArrayResource; import org.springframework.core.io.Resource; diff --git a/spring-batch-infrastructure/src/test/java/org/springframework/batch/io/file/FlatFileItemReaderBasicTests.java b/spring-batch-infrastructure/src/test/java/org/springframework/batch/item/file/FlatFileItemReaderBasicTests.java similarity index 95% rename from spring-batch-infrastructure/src/test/java/org/springframework/batch/io/file/FlatFileItemReaderBasicTests.java rename to spring-batch-infrastructure/src/test/java/org/springframework/batch/item/file/FlatFileItemReaderBasicTests.java index 61de6631c..6b8208230 100644 --- a/spring-batch-infrastructure/src/test/java/org/springframework/batch/io/file/FlatFileItemReaderBasicTests.java +++ b/spring-batch-infrastructure/src/test/java/org/springframework/batch/item/file/FlatFileItemReaderBasicTests.java @@ -14,7 +14,7 @@ * limitations under the License. */ -package org.springframework.batch.io.file; +package org.springframework.batch.item.file; import java.io.IOException; import java.io.InputStream; @@ -22,15 +22,15 @@ import java.io.InputStream; import junit.framework.TestCase; import org.springframework.batch.io.exception.FlatFileParsingException; -import org.springframework.batch.io.file.mapping.DefaultFieldSet; -import org.springframework.batch.io.file.mapping.FieldSet; -import org.springframework.batch.io.file.mapping.FieldSetMapper; -import org.springframework.batch.io.file.separator.DefaultRecordSeparatorPolicy; -import org.springframework.batch.io.file.transform.DelimitedLineTokenizer; -import org.springframework.batch.io.file.transform.LineTokenizer; import org.springframework.batch.item.ExecutionContext; import org.springframework.batch.item.ItemStreamException; import org.springframework.batch.item.ReaderNotOpenException; +import org.springframework.batch.item.file.mapping.DefaultFieldSet; +import org.springframework.batch.item.file.mapping.FieldSet; +import org.springframework.batch.item.file.mapping.FieldSetMapper; +import org.springframework.batch.item.file.separator.DefaultRecordSeparatorPolicy; +import org.springframework.batch.item.file.transform.DelimitedLineTokenizer; +import org.springframework.batch.item.file.transform.LineTokenizer; import org.springframework.core.io.AbstractResource; import org.springframework.core.io.ByteArrayResource; import org.springframework.core.io.Resource; diff --git a/spring-batch-infrastructure/src/test/java/org/springframework/batch/io/file/FlatFileItemWriterTests.java b/spring-batch-infrastructure/src/test/java/org/springframework/batch/item/file/FlatFileItemWriterTests.java similarity index 96% rename from spring-batch-infrastructure/src/test/java/org/springframework/batch/io/file/FlatFileItemWriterTests.java rename to spring-batch-infrastructure/src/test/java/org/springframework/batch/item/file/FlatFileItemWriterTests.java index 63fc95ec8..814372379 100644 --- a/spring-batch-infrastructure/src/test/java/org/springframework/batch/io/file/FlatFileItemWriterTests.java +++ b/spring-batch-infrastructure/src/test/java/org/springframework/batch/item/file/FlatFileItemWriterTests.java @@ -14,7 +14,7 @@ * limitations under the License. */ -package org.springframework.batch.io.file; +package org.springframework.batch.item.file; import java.io.BufferedReader; import java.io.File; @@ -23,11 +23,11 @@ import java.io.IOException; import junit.framework.TestCase; -import org.springframework.batch.io.file.mapping.DefaultFieldSet; -import org.springframework.batch.io.file.mapping.FieldSet; -import org.springframework.batch.io.file.mapping.FieldSetCreator; -import org.springframework.batch.io.file.mapping.PassThroughFieldSetMapper; import org.springframework.batch.item.ExecutionContext; +import org.springframework.batch.item.file.mapping.DefaultFieldSet; +import org.springframework.batch.item.file.mapping.FieldSet; +import org.springframework.batch.item.file.mapping.FieldSetCreator; +import org.springframework.batch.item.file.mapping.PassThroughFieldSetMapper; import org.springframework.core.io.FileSystemResource; import org.springframework.transaction.support.TransactionSynchronizationManager; diff --git a/spring-batch-infrastructure/src/test/java/org/springframework/batch/io/file/ResourceLineReaderTests.java b/spring-batch-infrastructure/src/test/java/org/springframework/batch/item/file/ResourceLineReaderTests.java similarity index 96% rename from spring-batch-infrastructure/src/test/java/org/springframework/batch/io/file/ResourceLineReaderTests.java rename to spring-batch-infrastructure/src/test/java/org/springframework/batch/item/file/ResourceLineReaderTests.java index 959dd8c5d..be88ecefe 100644 --- a/spring-batch-infrastructure/src/test/java/org/springframework/batch/io/file/ResourceLineReaderTests.java +++ b/spring-batch-infrastructure/src/test/java/org/springframework/batch/item/file/ResourceLineReaderTests.java @@ -14,17 +14,16 @@ * limitations under the License. */ -package org.springframework.batch.io.file; +package org.springframework.batch.item.file; import java.io.IOException; import java.io.InputStream; import junit.framework.TestCase; -import org.springframework.batch.io.file.separator.ResourceLineReader; -import org.springframework.batch.io.file.separator.SuffixRecordSeparatorPolicy; -import org.springframework.batch.item.ItemStreamException; import org.springframework.batch.item.UnexpectedInputException; +import org.springframework.batch.item.file.separator.ResourceLineReader; +import org.springframework.batch.item.file.separator.SuffixRecordSeparatorPolicy; import org.springframework.core.io.ByteArrayResource; import org.springframework.core.io.InputStreamResource; import org.springframework.core.io.Resource; diff --git a/spring-batch-infrastructure/src/test/java/org/springframework/batch/io/file/mapping/BeanWrapperFieldSetMapperTests.java b/spring-batch-infrastructure/src/test/java/org/springframework/batch/item/file/mapping/BeanWrapperFieldSetMapperTests.java similarity index 99% rename from spring-batch-infrastructure/src/test/java/org/springframework/batch/io/file/mapping/BeanWrapperFieldSetMapperTests.java rename to spring-batch-infrastructure/src/test/java/org/springframework/batch/item/file/mapping/BeanWrapperFieldSetMapperTests.java index 55fc1b246..6c6c76b97 100644 --- a/spring-batch-infrastructure/src/test/java/org/springframework/batch/io/file/mapping/BeanWrapperFieldSetMapperTests.java +++ b/spring-batch-infrastructure/src/test/java/org/springframework/batch/item/file/mapping/BeanWrapperFieldSetMapperTests.java @@ -14,7 +14,7 @@ * limitations under the License. */ -package org.springframework.batch.io.file.mapping; +package org.springframework.batch.item.file.mapping; import java.text.NumberFormat; import java.util.ArrayList; diff --git a/spring-batch-infrastructure/src/test/java/org/springframework/batch/io/file/mapping/PassThroughFieldSetMapperTests.java b/spring-batch-infrastructure/src/test/java/org/springframework/batch/item/file/mapping/PassThroughFieldSetMapperTests.java similarity index 75% rename from spring-batch-infrastructure/src/test/java/org/springframework/batch/io/file/mapping/PassThroughFieldSetMapperTests.java rename to spring-batch-infrastructure/src/test/java/org/springframework/batch/item/file/mapping/PassThroughFieldSetMapperTests.java index 39db6b1c5..54b8e6d42 100644 --- a/spring-batch-infrastructure/src/test/java/org/springframework/batch/io/file/mapping/PassThroughFieldSetMapperTests.java +++ b/spring-batch-infrastructure/src/test/java/org/springframework/batch/item/file/mapping/PassThroughFieldSetMapperTests.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package org.springframework.batch.io.file.mapping; +package org.springframework.batch.item.file.mapping; import junit.framework.TestCase; @@ -27,7 +27,7 @@ public class PassThroughFieldSetMapperTests extends TestCase { /** * Test method for - * {@link org.springframework.batch.io.file.mapping.PassThroughFieldSetMapper#mapLine(org.springframework.batch.io.file.mapping.FieldSet)}. + * {@link org.springframework.batch.item.file.mapping.PassThroughFieldSetMapper#mapLine(org.springframework.batch.item.file.mapping.FieldSet)}. */ public void testMapLine() { FieldSet fieldSet = new DefaultFieldSet(new String[] { "foo", "bar" }); @@ -36,7 +36,7 @@ public class PassThroughFieldSetMapperTests extends TestCase { /** * Test method for - * {@link org.springframework.batch.io.file.mapping.PassThroughFieldSetMapper#mapItem(java.lang.Object)}. + * {@link org.springframework.batch.item.file.mapping.PassThroughFieldSetMapper#mapItem(java.lang.Object)}. */ public void testUnmapItemAsFieldSet() { FieldSet fieldSet = new DefaultFieldSet(new String[] { "foo", "bar" }); @@ -45,7 +45,7 @@ public class PassThroughFieldSetMapperTests extends TestCase { /** * Test method for - * {@link org.springframework.batch.io.file.mapping.PassThroughFieldSetMapper#mapItem(java.lang.Object)}. + * {@link org.springframework.batch.item.file.mapping.PassThroughFieldSetMapper#mapItem(java.lang.Object)}. */ public void testUnmapItemAsString() { assertEquals(new DefaultFieldSet(new String[] { "foo" }), mapper.mapItem("foo")); @@ -53,7 +53,7 @@ public class PassThroughFieldSetMapperTests extends TestCase { /** * Test method for - * {@link org.springframework.batch.io.file.mapping.PassThroughFieldSetMapper#mapItem(java.lang.Object)}. + * {@link org.springframework.batch.item.file.mapping.PassThroughFieldSetMapper#mapItem(java.lang.Object)}. */ public void testUnmapItemAsNonString() { Object object = new Object(); diff --git a/spring-batch-infrastructure/src/test/java/org/springframework/batch/io/file/mapping/PropertyMatchesTests.java b/spring-batch-infrastructure/src/test/java/org/springframework/batch/item/file/mapping/PropertyMatchesTests.java similarity index 97% rename from spring-batch-infrastructure/src/test/java/org/springframework/batch/io/file/mapping/PropertyMatchesTests.java rename to spring-batch-infrastructure/src/test/java/org/springframework/batch/item/file/mapping/PropertyMatchesTests.java index e02bd8e5c..b2a8a4488 100644 --- a/spring-batch-infrastructure/src/test/java/org/springframework/batch/io/file/mapping/PropertyMatchesTests.java +++ b/spring-batch-infrastructure/src/test/java/org/springframework/batch/item/file/mapping/PropertyMatchesTests.java @@ -14,7 +14,7 @@ * limitations under the License. */ -package org.springframework.batch.io.file.mapping; +package org.springframework.batch.item.file.mapping; import junit.framework.TestCase; diff --git a/spring-batch-infrastructure/src/test/java/org/springframework/batch/io/file/mapping/TestObject.java b/spring-batch-infrastructure/src/test/java/org/springframework/batch/item/file/mapping/TestObject.java similarity index 97% rename from spring-batch-infrastructure/src/test/java/org/springframework/batch/io/file/mapping/TestObject.java rename to spring-batch-infrastructure/src/test/java/org/springframework/batch/item/file/mapping/TestObject.java index c3e096521..149021631 100644 --- a/spring-batch-infrastructure/src/test/java/org/springframework/batch/io/file/mapping/TestObject.java +++ b/spring-batch-infrastructure/src/test/java/org/springframework/batch/item/file/mapping/TestObject.java @@ -14,7 +14,7 @@ * limitations under the License. */ -package org.springframework.batch.io.file.mapping; +package org.springframework.batch.item.file.mapping; import java.math.BigDecimal; import java.util.Date; diff --git a/spring-batch-infrastructure/src/test/java/org/springframework/batch/io/file/separator/DefaultRecordSeparatorPolicyTests.java b/spring-batch-infrastructure/src/test/java/org/springframework/batch/item/file/separator/DefaultRecordSeparatorPolicyTests.java similarity index 97% rename from spring-batch-infrastructure/src/test/java/org/springframework/batch/io/file/separator/DefaultRecordSeparatorPolicyTests.java rename to spring-batch-infrastructure/src/test/java/org/springframework/batch/item/file/separator/DefaultRecordSeparatorPolicyTests.java index 8425932ee..fee7d672c 100644 --- a/spring-batch-infrastructure/src/test/java/org/springframework/batch/io/file/separator/DefaultRecordSeparatorPolicyTests.java +++ b/spring-batch-infrastructure/src/test/java/org/springframework/batch/item/file/separator/DefaultRecordSeparatorPolicyTests.java @@ -14,7 +14,7 @@ * limitations under the License. */ -package org.springframework.batch.io.file.separator; +package org.springframework.batch.item.file.separator; import junit.framework.TestCase; diff --git a/spring-batch-infrastructure/src/test/java/org/springframework/batch/io/file/separator/SimpleRecordSeparatorPolicyTests.java b/spring-batch-infrastructure/src/test/java/org/springframework/batch/item/file/separator/SimpleRecordSeparatorPolicyTests.java similarity index 96% rename from spring-batch-infrastructure/src/test/java/org/springframework/batch/io/file/separator/SimpleRecordSeparatorPolicyTests.java rename to spring-batch-infrastructure/src/test/java/org/springframework/batch/item/file/separator/SimpleRecordSeparatorPolicyTests.java index 2a95d1b23..7f824f117 100644 --- a/spring-batch-infrastructure/src/test/java/org/springframework/batch/io/file/separator/SimpleRecordSeparatorPolicyTests.java +++ b/spring-batch-infrastructure/src/test/java/org/springframework/batch/item/file/separator/SimpleRecordSeparatorPolicyTests.java @@ -14,7 +14,7 @@ * limitations under the License. */ -package org.springframework.batch.io.file.separator; +package org.springframework.batch.item.file.separator; import junit.framework.TestCase; diff --git a/spring-batch-infrastructure/src/test/java/org/springframework/batch/io/file/separator/SuffixRecordSeparatorPolicyTests.java b/spring-batch-infrastructure/src/test/java/org/springframework/batch/item/file/separator/SuffixRecordSeparatorPolicyTests.java similarity index 97% rename from spring-batch-infrastructure/src/test/java/org/springframework/batch/io/file/separator/SuffixRecordSeparatorPolicyTests.java rename to spring-batch-infrastructure/src/test/java/org/springframework/batch/item/file/separator/SuffixRecordSeparatorPolicyTests.java index bad53e097..dd0c03115 100644 --- a/spring-batch-infrastructure/src/test/java/org/springframework/batch/io/file/separator/SuffixRecordSeparatorPolicyTests.java +++ b/spring-batch-infrastructure/src/test/java/org/springframework/batch/item/file/separator/SuffixRecordSeparatorPolicyTests.java @@ -14,7 +14,7 @@ * limitations under the License. */ -package org.springframework.batch.io.file.separator; +package org.springframework.batch.item.file.separator; import junit.framework.TestCase; diff --git a/spring-batch-infrastructure/src/test/java/org/springframework/batch/io/file/transform/CommonLineTokenizerTests.java b/spring-batch-infrastructure/src/test/java/org/springframework/batch/item/file/transform/CommonLineTokenizerTests.java similarity index 93% rename from spring-batch-infrastructure/src/test/java/org/springframework/batch/io/file/transform/CommonLineTokenizerTests.java rename to spring-batch-infrastructure/src/test/java/org/springframework/batch/item/file/transform/CommonLineTokenizerTests.java index 0f889e2d5..420603e59 100644 --- a/spring-batch-infrastructure/src/test/java/org/springframework/batch/io/file/transform/CommonLineTokenizerTests.java +++ b/spring-batch-infrastructure/src/test/java/org/springframework/batch/item/file/transform/CommonLineTokenizerTests.java @@ -1,4 +1,4 @@ -package org.springframework.batch.io.file.transform; +package org.springframework.batch.item.file.transform; import java.util.List; diff --git a/spring-batch-infrastructure/src/test/java/org/springframework/batch/io/file/transform/DelimitedLineAggregatorTests.java b/spring-batch-infrastructure/src/test/java/org/springframework/batch/item/file/transform/DelimitedLineAggregatorTests.java similarity index 90% rename from spring-batch-infrastructure/src/test/java/org/springframework/batch/io/file/transform/DelimitedLineAggregatorTests.java rename to spring-batch-infrastructure/src/test/java/org/springframework/batch/item/file/transform/DelimitedLineAggregatorTests.java index debd4fcb2..ef061a4c1 100644 --- a/spring-batch-infrastructure/src/test/java/org/springframework/batch/io/file/transform/DelimitedLineAggregatorTests.java +++ b/spring-batch-infrastructure/src/test/java/org/springframework/batch/item/file/transform/DelimitedLineAggregatorTests.java @@ -14,11 +14,11 @@ * limitations under the License. */ -package org.springframework.batch.io.file.transform; +package org.springframework.batch.item.file.transform; import junit.framework.TestCase; -import org.springframework.batch.io.file.mapping.DefaultFieldSet; +import org.springframework.batch.item.file.mapping.DefaultFieldSet; /** * Unit tests for {@link DelimitedLineAggregator} diff --git a/spring-batch-infrastructure/src/test/java/org/springframework/batch/io/file/transform/DelimitedLineTokenizerTests.java b/spring-batch-infrastructure/src/test/java/org/springframework/batch/item/file/transform/DelimitedLineTokenizerTests.java similarity index 98% rename from spring-batch-infrastructure/src/test/java/org/springframework/batch/io/file/transform/DelimitedLineTokenizerTests.java rename to spring-batch-infrastructure/src/test/java/org/springframework/batch/item/file/transform/DelimitedLineTokenizerTests.java index a102414bb..45ae5649a 100644 --- a/spring-batch-infrastructure/src/test/java/org/springframework/batch/io/file/transform/DelimitedLineTokenizerTests.java +++ b/spring-batch-infrastructure/src/test/java/org/springframework/batch/item/file/transform/DelimitedLineTokenizerTests.java @@ -14,11 +14,11 @@ * limitations under the License. */ -package org.springframework.batch.io.file.transform; +package org.springframework.batch.item.file.transform; import junit.framework.TestCase; -import org.springframework.batch.io.file.mapping.FieldSet; +import org.springframework.batch.item.file.mapping.FieldSet; public class DelimitedLineTokenizerTests extends TestCase { diff --git a/spring-batch-infrastructure/src/test/java/org/springframework/batch/io/file/transform/FixedLengthLineAggregatorTests.java b/spring-batch-infrastructure/src/test/java/org/springframework/batch/item/file/transform/FixedLengthLineAggregatorTests.java similarity index 97% rename from spring-batch-infrastructure/src/test/java/org/springframework/batch/io/file/transform/FixedLengthLineAggregatorTests.java rename to spring-batch-infrastructure/src/test/java/org/springframework/batch/item/file/transform/FixedLengthLineAggregatorTests.java index 1cb72b32e..70aa02be2 100644 --- a/spring-batch-infrastructure/src/test/java/org/springframework/batch/io/file/transform/FixedLengthLineAggregatorTests.java +++ b/spring-batch-infrastructure/src/test/java/org/springframework/batch/item/file/transform/FixedLengthLineAggregatorTests.java @@ -14,11 +14,11 @@ * limitations under the License. */ -package org.springframework.batch.io.file.transform; +package org.springframework.batch.item.file.transform; import junit.framework.TestCase; -import org.springframework.batch.io.file.mapping.DefaultFieldSet; +import org.springframework.batch.item.file.mapping.DefaultFieldSet; /** * Unit tests for {@link FixedLengthLineAggregator} diff --git a/spring-batch-infrastructure/src/test/java/org/springframework/batch/io/file/transform/FixedLengthTokenizerTests.java b/spring-batch-infrastructure/src/test/java/org/springframework/batch/item/file/transform/FixedLengthTokenizerTests.java similarity index 97% rename from spring-batch-infrastructure/src/test/java/org/springframework/batch/io/file/transform/FixedLengthTokenizerTests.java rename to spring-batch-infrastructure/src/test/java/org/springframework/batch/item/file/transform/FixedLengthTokenizerTests.java index 0ff3a2a70..7dd379cc8 100644 --- a/spring-batch-infrastructure/src/test/java/org/springframework/batch/io/file/transform/FixedLengthTokenizerTests.java +++ b/spring-batch-infrastructure/src/test/java/org/springframework/batch/item/file/transform/FixedLengthTokenizerTests.java @@ -14,11 +14,11 @@ * limitations under the License. */ -package org.springframework.batch.io.file.transform; +package org.springframework.batch.item.file.transform; import junit.framework.TestCase; -import org.springframework.batch.io.file.mapping.FieldSet; +import org.springframework.batch.item.file.mapping.FieldSet; public class FixedLengthTokenizerTests extends TestCase { diff --git a/spring-batch-infrastructure/src/test/java/org/springframework/batch/io/file/transform/LineAggregatorItemTransformerTests.java b/spring-batch-infrastructure/src/test/java/org/springframework/batch/item/file/transform/LineAggregatorItemTransformerTests.java similarity index 74% rename from spring-batch-infrastructure/src/test/java/org/springframework/batch/io/file/transform/LineAggregatorItemTransformerTests.java rename to spring-batch-infrastructure/src/test/java/org/springframework/batch/item/file/transform/LineAggregatorItemTransformerTests.java index ea174f830..b58ead759 100644 --- a/spring-batch-infrastructure/src/test/java/org/springframework/batch/io/file/transform/LineAggregatorItemTransformerTests.java +++ b/spring-batch-infrastructure/src/test/java/org/springframework/batch/item/file/transform/LineAggregatorItemTransformerTests.java @@ -13,11 +13,11 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package org.springframework.batch.io.file.transform; +package org.springframework.batch.item.file.transform; import junit.framework.TestCase; -import org.springframework.batch.io.file.mapping.FieldSet; +import org.springframework.batch.item.file.mapping.FieldSet; /** * @author Dave Syer @@ -28,7 +28,7 @@ public class LineAggregatorItemTransformerTests extends TestCase { private LineAggregatorItemTransformer transformer = new LineAggregatorItemTransformer(); /** - * Test method for {@link org.springframework.batch.io.file.transform.LineAggregatorItemTransformer#setAggregator(org.springframework.batch.io.file.transform.LineAggregator)}. + * Test method for {@link org.springframework.batch.item.file.transform.LineAggregatorItemTransformer#setAggregator(org.springframework.batch.item.file.transform.LineAggregator)}. * @throws Exception */ public void testSetAggregator() throws Exception { @@ -42,7 +42,7 @@ public class LineAggregatorItemTransformerTests extends TestCase { } /** - * Test method for {@link org.springframework.batch.io.file.transform.LineAggregatorItemTransformer#transform(java.lang.Object)}. + * Test method for {@link org.springframework.batch.item.file.transform.LineAggregatorItemTransformer#transform(java.lang.Object)}. * @throws Exception */ public void testTransform() throws Exception { @@ -51,7 +51,7 @@ public class LineAggregatorItemTransformerTests extends TestCase { } /** - * Test method for {@link org.springframework.batch.io.file.transform.LineAggregatorItemTransformer#transform(java.lang.Object)}. + * Test method for {@link org.springframework.batch.item.file.transform.LineAggregatorItemTransformer#transform(java.lang.Object)}. * @throws Exception */ public void testTransformWrongType() throws Exception { diff --git a/spring-batch-infrastructure/src/test/java/org/springframework/batch/io/file/transform/PrefixMatchingCompositeLineTokenizerTests.java b/spring-batch-infrastructure/src/test/java/org/springframework/batch/item/file/transform/PrefixMatchingCompositeLineTokenizerTests.java similarity index 93% rename from spring-batch-infrastructure/src/test/java/org/springframework/batch/io/file/transform/PrefixMatchingCompositeLineTokenizerTests.java rename to spring-batch-infrastructure/src/test/java/org/springframework/batch/item/file/transform/PrefixMatchingCompositeLineTokenizerTests.java index 5609ef180..6af142b03 100644 --- a/spring-batch-infrastructure/src/test/java/org/springframework/batch/io/file/transform/PrefixMatchingCompositeLineTokenizerTests.java +++ b/spring-batch-infrastructure/src/test/java/org/springframework/batch/item/file/transform/PrefixMatchingCompositeLineTokenizerTests.java @@ -14,7 +14,7 @@ * limitations under the License. */ -package org.springframework.batch.io.file.transform; +package org.springframework.batch.item.file.transform; import java.util.Collections; import java.util.HashMap; @@ -23,8 +23,8 @@ import java.util.Map; import junit.framework.TestCase; -import org.springframework.batch.io.file.mapping.DefaultFieldSet; -import org.springframework.batch.io.file.mapping.FieldSet; +import org.springframework.batch.item.file.mapping.DefaultFieldSet; +import org.springframework.batch.item.file.mapping.FieldSet; public class PrefixMatchingCompositeLineTokenizerTests extends TestCase { diff --git a/spring-batch-infrastructure/src/test/java/org/springframework/batch/io/file/transform/RangeArrayPropertyEditorTests.java b/spring-batch-infrastructure/src/test/java/org/springframework/batch/item/file/transform/RangeArrayPropertyEditorTests.java similarity index 97% rename from spring-batch-infrastructure/src/test/java/org/springframework/batch/io/file/transform/RangeArrayPropertyEditorTests.java rename to spring-batch-infrastructure/src/test/java/org/springframework/batch/item/file/transform/RangeArrayPropertyEditorTests.java index 6151635b5..a45ade8b1 100644 --- a/spring-batch-infrastructure/src/test/java/org/springframework/batch/io/file/transform/RangeArrayPropertyEditorTests.java +++ b/spring-batch-infrastructure/src/test/java/org/springframework/batch/item/file/transform/RangeArrayPropertyEditorTests.java @@ -1,4 +1,4 @@ -package org.springframework.batch.io.file.transform; +package org.springframework.batch.item.file.transform; import junit.framework.TestCase; diff --git a/spring-batch-infrastructure/src/test/java/org/springframework/batch/io/file/transform/RecursiveCollectionItemTransformerTests.java b/spring-batch-infrastructure/src/test/java/org/springframework/batch/item/file/transform/RecursiveCollectionItemTransformerTests.java similarity index 76% rename from spring-batch-infrastructure/src/test/java/org/springframework/batch/io/file/transform/RecursiveCollectionItemTransformerTests.java rename to spring-batch-infrastructure/src/test/java/org/springframework/batch/item/file/transform/RecursiveCollectionItemTransformerTests.java index bc9c7f43a..625f0869a 100644 --- a/spring-batch-infrastructure/src/test/java/org/springframework/batch/io/file/transform/RecursiveCollectionItemTransformerTests.java +++ b/spring-batch-infrastructure/src/test/java/org/springframework/batch/item/file/transform/RecursiveCollectionItemTransformerTests.java @@ -13,14 +13,14 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package org.springframework.batch.io.file.transform; +package org.springframework.batch.item.file.transform; import java.util.Arrays; import java.util.Collections; import junit.framework.TestCase; -import org.springframework.batch.item.writer.ItemTransformer; +import org.springframework.batch.item.transform.ItemTransformer; import org.springframework.util.StringUtils; /** @@ -35,7 +35,7 @@ public class RecursiveCollectionItemTransformerTests extends TestCase { /** * Test method for - * {@link org.springframework.batch.io.file.transform.RecursiveCollectionItemTransformer#setDelegate(org.springframework.batch.item.writer.ItemTransformer)}. + * {@link org.springframework.batch.item.file.transform.RecursiveCollectionItemTransformer#setDelegate(org.springframework.batch.item.transform.ItemTransformer)}. * @throws Exception */ public void testSetDelegate() throws Exception { @@ -49,7 +49,7 @@ public class RecursiveCollectionItemTransformerTests extends TestCase { /** * Test method for - * {@link org.springframework.batch.io.file.transform.RecursiveCollectionItemTransformer#setDelegate(org.springframework.batch.item.writer.ItemTransformer)}. + * {@link org.springframework.batch.item.file.transform.RecursiveCollectionItemTransformer#setDelegate(org.springframework.batch.item.transform.ItemTransformer)}. * @throws Exception */ public void testSetDelegateAndPassInString() throws Exception { @@ -63,7 +63,7 @@ public class RecursiveCollectionItemTransformerTests extends TestCase { /** * Test method for - * {@link org.springframework.batch.io.file.transform.RecursiveCollectionItemTransformer#setDelegate(org.springframework.batch.item.writer.ItemTransformer)}. + * {@link org.springframework.batch.item.file.transform.RecursiveCollectionItemTransformer#setDelegate(org.springframework.batch.item.transform.ItemTransformer)}. * @throws Exception */ public void testSetDelegateReturnsList() throws Exception { @@ -79,7 +79,7 @@ public class RecursiveCollectionItemTransformerTests extends TestCase { /** * Test method for - * {@link org.springframework.batch.io.file.transform.RecursiveCollectionItemTransformer#transform(java.lang.Object)}. + * {@link org.springframework.batch.item.file.transform.RecursiveCollectionItemTransformer#transform(java.lang.Object)}. * @throws Exception */ public void testTransformString() throws Exception { @@ -88,7 +88,7 @@ public class RecursiveCollectionItemTransformerTests extends TestCase { /** * Test method for - * {@link org.springframework.batch.io.file.transform.RecursiveCollectionItemTransformer#transform(java.lang.Object)}. + * {@link org.springframework.batch.item.file.transform.RecursiveCollectionItemTransformer#transform(java.lang.Object)}. * @throws Exception */ public void testTransformArray() throws Exception { @@ -100,7 +100,7 @@ public class RecursiveCollectionItemTransformerTests extends TestCase { /** * Test method for - * {@link org.springframework.batch.io.file.transform.RecursiveCollectionItemTransformer#transform(java.lang.Object)}. + * {@link org.springframework.batch.item.file.transform.RecursiveCollectionItemTransformer#transform(java.lang.Object)}. * @throws Exception */ public void testTransformList() throws Exception { @@ -112,7 +112,7 @@ public class RecursiveCollectionItemTransformerTests extends TestCase { /** * Test method for - * {@link org.springframework.batch.io.file.transform.RecursiveCollectionItemTransformer#transform(java.lang.Object)}. + * {@link org.springframework.batch.item.file.transform.RecursiveCollectionItemTransformer#transform(java.lang.Object)}. * @throws Exception */ public void testTransformArrayOfArrays() throws Exception { diff --git a/spring-batch-infrastructure/src/test/java/org/springframework/batch/io/file/transform/StubLineAggregator.java b/spring-batch-infrastructure/src/test/java/org/springframework/batch/item/file/transform/StubLineAggregator.java similarity index 89% rename from spring-batch-infrastructure/src/test/java/org/springframework/batch/io/file/transform/StubLineAggregator.java rename to spring-batch-infrastructure/src/test/java/org/springframework/batch/item/file/transform/StubLineAggregator.java index 28a0cbe7f..9d351ca2e 100644 --- a/spring-batch-infrastructure/src/test/java/org/springframework/batch/io/file/transform/StubLineAggregator.java +++ b/spring-batch-infrastructure/src/test/java/org/springframework/batch/item/file/transform/StubLineAggregator.java @@ -14,9 +14,9 @@ * limitations under the License. */ -package org.springframework.batch.io.file.transform; +package org.springframework.batch.item.file.transform; -import org.springframework.batch.io.file.mapping.FieldSet; +import org.springframework.batch.item.file.mapping.FieldSet; /** diff --git a/spring-batch-infrastructure/src/test/java/org/springframework/batch/item/reader/DelegatingItemReaderTests.java b/spring-batch-infrastructure/src/test/java/org/springframework/batch/item/reader/DelegatingItemReaderTests.java index 86b7c08d8..c609ecb30 100644 --- a/spring-batch-infrastructure/src/test/java/org/springframework/batch/item/reader/DelegatingItemReaderTests.java +++ b/spring-batch-infrastructure/src/test/java/org/springframework/batch/item/reader/DelegatingItemReaderTests.java @@ -18,10 +18,11 @@ package org.springframework.batch.item.reader; import junit.framework.TestCase; -import org.springframework.batch.io.Skippable; +import org.springframework.batch.item.AbstractItemReader; import org.springframework.batch.item.ExecutionContext; import org.springframework.batch.item.ItemReader; import org.springframework.batch.item.ItemStream; +import org.springframework.batch.item.Skippable; /** * Unit test for {@link DelegatingItemReader} diff --git a/spring-batch-infrastructure/src/test/java/org/springframework/batch/item/stream/SimpleStreamManagerTests.java b/spring-batch-infrastructure/src/test/java/org/springframework/batch/item/stream/SimpleStreamManagerTests.java index 42f75f660..f2541151a 100644 --- a/spring-batch-infrastructure/src/test/java/org/springframework/batch/item/stream/SimpleStreamManagerTests.java +++ b/spring-batch-infrastructure/src/test/java/org/springframework/batch/item/stream/SimpleStreamManagerTests.java @@ -23,6 +23,7 @@ import junit.framework.TestCase; import org.springframework.batch.item.ExecutionContext; import org.springframework.batch.item.ItemStream; import org.springframework.batch.item.ItemStreamException; +import org.springframework.batch.item.ItemStreamSupport; /** * @author Dave Syer diff --git a/spring-batch-infrastructure/src/test/java/org/springframework/batch/io/support/FileUtilsTests.java b/spring-batch-infrastructure/src/test/java/org/springframework/batch/item/support/FileUtilsTests.java similarity index 96% rename from spring-batch-infrastructure/src/test/java/org/springframework/batch/io/support/FileUtilsTests.java rename to spring-batch-infrastructure/src/test/java/org/springframework/batch/item/support/FileUtilsTests.java index 296f564ee..d43adaa96 100644 --- a/spring-batch-infrastructure/src/test/java/org/springframework/batch/io/support/FileUtilsTests.java +++ b/spring-batch-infrastructure/src/test/java/org/springframework/batch/item/support/FileUtilsTests.java @@ -1,4 +1,4 @@ -package org.springframework.batch.io.support; +package org.springframework.batch.item.support; import java.io.BufferedWriter; import java.io.File; @@ -7,6 +7,7 @@ import java.io.IOException; import junit.framework.TestCase; +import org.springframework.batch.item.support.FileUtils; import org.springframework.dao.DataAccessResourceFailureException; import org.springframework.util.Assert; diff --git a/spring-batch-infrastructure/src/test/java/org/springframework/batch/item/writer/CompositeItemTransformerTests.java b/spring-batch-infrastructure/src/test/java/org/springframework/batch/item/transform/CompositeItemTransformerTests.java similarity index 92% rename from spring-batch-infrastructure/src/test/java/org/springframework/batch/item/writer/CompositeItemTransformerTests.java rename to spring-batch-infrastructure/src/test/java/org/springframework/batch/item/transform/CompositeItemTransformerTests.java index 5b79468b5..71496532b 100644 --- a/spring-batch-infrastructure/src/test/java/org/springframework/batch/item/writer/CompositeItemTransformerTests.java +++ b/spring-batch-infrastructure/src/test/java/org/springframework/batch/item/transform/CompositeItemTransformerTests.java @@ -1,10 +1,12 @@ -package org.springframework.batch.item.writer; +package org.springframework.batch.item.transform; import java.util.ArrayList; import junit.framework.TestCase; import org.easymock.MockControl; +import org.springframework.batch.item.transform.CompositeItemTransformer; +import org.springframework.batch.item.transform.ItemTransformer; /** * Tests for {@link CompositeItemTransformer}. diff --git a/spring-batch-infrastructure/src/test/java/org/springframework/batch/item/writer/ItemTransformerItemWriterTests.java b/spring-batch-infrastructure/src/test/java/org/springframework/batch/item/transform/ItemTransformerItemWriterTests.java similarity index 89% rename from spring-batch-infrastructure/src/test/java/org/springframework/batch/item/writer/ItemTransformerItemWriterTests.java rename to spring-batch-infrastructure/src/test/java/org/springframework/batch/item/transform/ItemTransformerItemWriterTests.java index b22efca22..6b1189b96 100644 --- a/spring-batch-infrastructure/src/test/java/org/springframework/batch/item/writer/ItemTransformerItemWriterTests.java +++ b/spring-batch-infrastructure/src/test/java/org/springframework/batch/item/transform/ItemTransformerItemWriterTests.java @@ -1,9 +1,11 @@ -package org.springframework.batch.item.writer; +package org.springframework.batch.item.transform; import junit.framework.TestCase; import org.easymock.MockControl; import org.springframework.batch.item.ItemWriter; +import org.springframework.batch.item.transform.ItemTransformer; +import org.springframework.batch.item.transform.ItemTransformerItemWriter; /** * Tests for {@link ItemTransformerItemWriter}. diff --git a/spring-batch-infrastructure/src/test/java/org/springframework/batch/item/reader/ValidatingItemReaderTests.java b/spring-batch-infrastructure/src/test/java/org/springframework/batch/item/validator/ValidatingItemReaderTests.java similarity index 94% rename from spring-batch-infrastructure/src/test/java/org/springframework/batch/item/reader/ValidatingItemReaderTests.java rename to spring-batch-infrastructure/src/test/java/org/springframework/batch/item/validator/ValidatingItemReaderTests.java index 6650f4268..11eb635b4 100644 --- a/spring-batch-infrastructure/src/test/java/org/springframework/batch/item/reader/ValidatingItemReaderTests.java +++ b/spring-batch-infrastructure/src/test/java/org/springframework/batch/item/validator/ValidatingItemReaderTests.java @@ -13,13 +13,15 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package org.springframework.batch.item.reader; +package org.springframework.batch.item.validator; import junit.framework.TestCase; import org.easymock.MockControl; import org.springframework.batch.io.exception.ValidationException; +import org.springframework.batch.item.AbstractItemReader; import org.springframework.batch.item.ItemReader; +import org.springframework.batch.item.validator.ValidatingItemReader; import org.springframework.batch.item.validator.Validator; /** diff --git a/spring-batch-infrastructure/src/test/java/org/springframework/batch/io/xml/EventHelper.java b/spring-batch-infrastructure/src/test/java/org/springframework/batch/item/xml/EventHelper.java similarity index 93% rename from spring-batch-infrastructure/src/test/java/org/springframework/batch/io/xml/EventHelper.java rename to spring-batch-infrastructure/src/test/java/org/springframework/batch/item/xml/EventHelper.java index 081d5c524..f1b9a55bd 100644 --- a/spring-batch-infrastructure/src/test/java/org/springframework/batch/io/xml/EventHelper.java +++ b/spring-batch-infrastructure/src/test/java/org/springframework/batch/item/xml/EventHelper.java @@ -1,4 +1,4 @@ -package org.springframework.batch.io.xml; +package org.springframework.batch.item.xml; import javax.xml.stream.events.EndElement; import javax.xml.stream.events.StartElement; diff --git a/spring-batch-infrastructure/src/test/java/org/springframework/batch/io/xml/StaxEventItemReaderTests.java b/spring-batch-infrastructure/src/test/java/org/springframework/batch/item/xml/StaxEventItemReaderTests.java similarity index 99% rename from spring-batch-infrastructure/src/test/java/org/springframework/batch/io/xml/StaxEventItemReaderTests.java rename to spring-batch-infrastructure/src/test/java/org/springframework/batch/item/xml/StaxEventItemReaderTests.java index 8acdc01a6..bc1d93791 100644 --- a/spring-batch-infrastructure/src/test/java/org/springframework/batch/io/xml/StaxEventItemReaderTests.java +++ b/spring-batch-infrastructure/src/test/java/org/springframework/batch/item/xml/StaxEventItemReaderTests.java @@ -1,4 +1,4 @@ -package org.springframework.batch.io.xml; +package org.springframework.batch.item.xml; import java.io.IOException; import java.io.InputStream; diff --git a/spring-batch-infrastructure/src/test/java/org/springframework/batch/io/xml/StaxEventItemWriterTests.java b/spring-batch-infrastructure/src/test/java/org/springframework/batch/item/xml/StaxEventItemWriterTests.java similarity index 98% rename from spring-batch-infrastructure/src/test/java/org/springframework/batch/io/xml/StaxEventItemWriterTests.java rename to spring-batch-infrastructure/src/test/java/org/springframework/batch/item/xml/StaxEventItemWriterTests.java index ef84fc0a3..c6f003534 100644 --- a/spring-batch-infrastructure/src/test/java/org/springframework/batch/io/xml/StaxEventItemWriterTests.java +++ b/spring-batch-infrastructure/src/test/java/org/springframework/batch/item/xml/StaxEventItemWriterTests.java @@ -1,4 +1,4 @@ -package org.springframework.batch.io.xml; +package org.springframework.batch.item.xml; import java.io.File; import java.io.IOException; @@ -11,8 +11,8 @@ import javax.xml.transform.Result; import junit.framework.TestCase; import org.apache.commons.io.FileUtils; -import org.springframework.batch.io.xml.oxm.MarshallingEventWriterSerializer; import org.springframework.batch.item.ExecutionContext; +import org.springframework.batch.item.xml.oxm.MarshallingEventWriterSerializer; import org.springframework.core.io.FileSystemResource; import org.springframework.core.io.Resource; import org.springframework.oxm.Marshaller; diff --git a/spring-batch-infrastructure/src/test/java/org/springframework/batch/io/xml/oxm/MarshallingObjectToXmlSerializerTests.java b/spring-batch-infrastructure/src/test/java/org/springframework/batch/item/xml/oxm/MarshallingObjectToXmlSerializerTests.java similarity index 98% rename from spring-batch-infrastructure/src/test/java/org/springframework/batch/io/xml/oxm/MarshallingObjectToXmlSerializerTests.java rename to spring-batch-infrastructure/src/test/java/org/springframework/batch/item/xml/oxm/MarshallingObjectToXmlSerializerTests.java index 0a6d01931..35de43a4d 100644 --- a/spring-batch-infrastructure/src/test/java/org/springframework/batch/io/xml/oxm/MarshallingObjectToXmlSerializerTests.java +++ b/spring-batch-infrastructure/src/test/java/org/springframework/batch/item/xml/oxm/MarshallingObjectToXmlSerializerTests.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package org.springframework.batch.io.xml.oxm; +package org.springframework.batch.item.xml.oxm; import java.io.IOException; diff --git a/spring-batch-infrastructure/src/test/java/org/springframework/batch/io/xml/oxm/UnmarshallingFragmentDeserializerTests.java b/spring-batch-infrastructure/src/test/java/org/springframework/batch/item/xml/oxm/UnmarshallingFragmentDeserializerTests.java similarity index 98% rename from spring-batch-infrastructure/src/test/java/org/springframework/batch/io/xml/oxm/UnmarshallingFragmentDeserializerTests.java rename to spring-batch-infrastructure/src/test/java/org/springframework/batch/item/xml/oxm/UnmarshallingFragmentDeserializerTests.java index 731f28a05..fc67e087e 100644 --- a/spring-batch-infrastructure/src/test/java/org/springframework/batch/io/xml/oxm/UnmarshallingFragmentDeserializerTests.java +++ b/spring-batch-infrastructure/src/test/java/org/springframework/batch/item/xml/oxm/UnmarshallingFragmentDeserializerTests.java @@ -1,4 +1,4 @@ -package org.springframework.batch.io.xml.oxm; +package org.springframework.batch.item.xml.oxm; import java.io.IOException; diff --git a/spring-batch-infrastructure/src/test/java/org/springframework/batch/io/xml/stax/AbstractEventReaderWrapperTests.java b/spring-batch-infrastructure/src/test/java/org/springframework/batch/item/xml/stax/AbstractEventReaderWrapperTests.java similarity index 98% rename from spring-batch-infrastructure/src/test/java/org/springframework/batch/io/xml/stax/AbstractEventReaderWrapperTests.java rename to spring-batch-infrastructure/src/test/java/org/springframework/batch/item/xml/stax/AbstractEventReaderWrapperTests.java index 06b2922ef..54c76c04c 100644 --- a/spring-batch-infrastructure/src/test/java/org/springframework/batch/io/xml/stax/AbstractEventReaderWrapperTests.java +++ b/spring-batch-infrastructure/src/test/java/org/springframework/batch/item/xml/stax/AbstractEventReaderWrapperTests.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package org.springframework.batch.io.xml.stax; +package org.springframework.batch.item.xml.stax; import javax.xml.stream.XMLEventReader; import javax.xml.stream.XMLStreamException; diff --git a/spring-batch-infrastructure/src/test/java/org/springframework/batch/io/xml/stax/AbstractEventWriterWrapperTests.java b/spring-batch-infrastructure/src/test/java/org/springframework/batch/item/xml/stax/AbstractEventWriterWrapperTests.java similarity index 98% rename from spring-batch-infrastructure/src/test/java/org/springframework/batch/io/xml/stax/AbstractEventWriterWrapperTests.java rename to spring-batch-infrastructure/src/test/java/org/springframework/batch/item/xml/stax/AbstractEventWriterWrapperTests.java index 7515f6927..0cc337c85 100644 --- a/spring-batch-infrastructure/src/test/java/org/springframework/batch/io/xml/stax/AbstractEventWriterWrapperTests.java +++ b/spring-batch-infrastructure/src/test/java/org/springframework/batch/item/xml/stax/AbstractEventWriterWrapperTests.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package org.springframework.batch.io.xml.stax; +package org.springframework.batch.item.xml.stax; import javax.xml.namespace.NamespaceContext; import javax.xml.stream.XMLEventReader; diff --git a/spring-batch-infrastructure/src/test/java/org/springframework/batch/io/xml/stax/DefaultFragmentEventReaderTests.java b/spring-batch-infrastructure/src/test/java/org/springframework/batch/item/xml/stax/DefaultFragmentEventReaderTests.java similarity index 97% rename from spring-batch-infrastructure/src/test/java/org/springframework/batch/io/xml/stax/DefaultFragmentEventReaderTests.java rename to spring-batch-infrastructure/src/test/java/org/springframework/batch/item/xml/stax/DefaultFragmentEventReaderTests.java index c8f12076c..705a356e6 100644 --- a/spring-batch-infrastructure/src/test/java/org/springframework/batch/io/xml/stax/DefaultFragmentEventReaderTests.java +++ b/spring-batch-infrastructure/src/test/java/org/springframework/batch/item/xml/stax/DefaultFragmentEventReaderTests.java @@ -1,4 +1,4 @@ -package org.springframework.batch.io.xml.stax; +package org.springframework.batch.item.xml.stax; import java.util.NoSuchElementException; @@ -9,7 +9,7 @@ import javax.xml.stream.events.XMLEvent; import junit.framework.TestCase; -import org.springframework.batch.io.xml.EventHelper; +import org.springframework.batch.item.xml.EventHelper; import org.springframework.core.io.ByteArrayResource; import org.springframework.core.io.Resource; diff --git a/spring-batch-infrastructure/src/test/java/org/springframework/batch/io/xml/stax/DefaultTransactionalEventReaderTests.java b/spring-batch-infrastructure/src/test/java/org/springframework/batch/item/xml/stax/DefaultTransactionalEventReaderTests.java similarity index 94% rename from spring-batch-infrastructure/src/test/java/org/springframework/batch/io/xml/stax/DefaultTransactionalEventReaderTests.java rename to spring-batch-infrastructure/src/test/java/org/springframework/batch/item/xml/stax/DefaultTransactionalEventReaderTests.java index 106e850f1..be6b578b1 100644 --- a/spring-batch-infrastructure/src/test/java/org/springframework/batch/io/xml/stax/DefaultTransactionalEventReaderTests.java +++ b/spring-batch-infrastructure/src/test/java/org/springframework/batch/item/xml/stax/DefaultTransactionalEventReaderTests.java @@ -1,11 +1,11 @@ -package org.springframework.batch.io.xml.stax; +package org.springframework.batch.item.xml.stax; import javax.xml.stream.XMLEventReader; import javax.xml.stream.XMLInputFactory; import junit.framework.TestCase; -import org.springframework.batch.io.xml.EventHelper; +import org.springframework.batch.item.xml.EventHelper; import org.springframework.core.io.ByteArrayResource; import org.springframework.core.io.Resource; diff --git a/spring-batch-infrastructure/src/test/java/org/springframework/batch/io/xml/stax/EventSequenceTests.java b/spring-batch-infrastructure/src/test/java/org/springframework/batch/item/xml/stax/EventSequenceTests.java similarity index 94% rename from spring-batch-infrastructure/src/test/java/org/springframework/batch/io/xml/stax/EventSequenceTests.java rename to spring-batch-infrastructure/src/test/java/org/springframework/batch/item/xml/stax/EventSequenceTests.java index 32eccfaaa..052bb6d77 100644 --- a/spring-batch-infrastructure/src/test/java/org/springframework/batch/io/xml/stax/EventSequenceTests.java +++ b/spring-batch-infrastructure/src/test/java/org/springframework/batch/item/xml/stax/EventSequenceTests.java @@ -1,4 +1,4 @@ -package org.springframework.batch.io.xml.stax; +package org.springframework.batch.item.xml.stax; import javax.xml.stream.XMLEventFactory; import javax.xml.stream.events.XMLEvent; diff --git a/spring-batch-infrastructure/src/test/java/org/springframework/batch/io/xml/stax/NoStartEndDocumentWriterTests.java b/spring-batch-infrastructure/src/test/java/org/springframework/batch/item/xml/stax/NoStartEndDocumentWriterTests.java similarity index 96% rename from spring-batch-infrastructure/src/test/java/org/springframework/batch/io/xml/stax/NoStartEndDocumentWriterTests.java rename to spring-batch-infrastructure/src/test/java/org/springframework/batch/item/xml/stax/NoStartEndDocumentWriterTests.java index 9f4d697c0..d5c37a408 100644 --- a/spring-batch-infrastructure/src/test/java/org/springframework/batch/io/xml/stax/NoStartEndDocumentWriterTests.java +++ b/spring-batch-infrastructure/src/test/java/org/springframework/batch/item/xml/stax/NoStartEndDocumentWriterTests.java @@ -1,4 +1,4 @@ -package org.springframework.batch.io.xml.stax; +package org.springframework.batch.item.xml.stax; import javax.xml.stream.XMLEventFactory; import javax.xml.stream.XMLEventWriter; diff --git a/spring-batch-infrastructure/src/test/java/org/springframework/batch/repeat/callback/ItemReaderRepeatCallbackTests.java b/spring-batch-infrastructure/src/test/java/org/springframework/batch/repeat/callback/ItemReaderRepeatCallbackTests.java index 6827cc644..c15aeaf37 100644 --- a/spring-batch-infrastructure/src/test/java/org/springframework/batch/repeat/callback/ItemReaderRepeatCallbackTests.java +++ b/spring-batch-infrastructure/src/test/java/org/springframework/batch/repeat/callback/ItemReaderRepeatCallbackTests.java @@ -22,8 +22,8 @@ import java.util.List; import junit.framework.TestCase; +import org.springframework.batch.item.AbstractItemWriter; import org.springframework.batch.item.reader.ListItemReader; -import org.springframework.batch.item.writer.AbstractItemWriter; public class ItemReaderRepeatCallbackTests extends TestCase { diff --git a/spring-batch-infrastructure/src/test/java/org/springframework/batch/repeat/support/AbstractTradeBatchTests.java b/spring-batch-infrastructure/src/test/java/org/springframework/batch/repeat/support/AbstractTradeBatchTests.java index 1b848a62b..36ab5c9b8 100644 --- a/spring-batch-infrastructure/src/test/java/org/springframework/batch/repeat/support/AbstractTradeBatchTests.java +++ b/spring-batch-infrastructure/src/test/java/org/springframework/batch/repeat/support/AbstractTradeBatchTests.java @@ -18,11 +18,11 @@ package org.springframework.batch.repeat.support; import junit.framework.TestCase; -import org.springframework.batch.io.file.FlatFileItemReader; -import org.springframework.batch.io.file.mapping.FieldSet; -import org.springframework.batch.io.file.mapping.FieldSetMapper; +import org.springframework.batch.item.AbstractItemWriter; import org.springframework.batch.item.ExecutionContext; -import org.springframework.batch.item.writer.AbstractItemWriter; +import org.springframework.batch.item.file.FlatFileItemReader; +import org.springframework.batch.item.file.mapping.FieldSet; +import org.springframework.batch.item.file.mapping.FieldSetMapper; import org.springframework.core.io.ClassPathResource; import org.springframework.core.io.Resource; diff --git a/spring-batch-infrastructure/src/test/java/org/springframework/batch/repeat/support/ChunkedRepeatTests.java b/spring-batch-infrastructure/src/test/java/org/springframework/batch/repeat/support/ChunkedRepeatTests.java index 729e562bf..7fb76d582 100644 --- a/spring-batch-infrastructure/src/test/java/org/springframework/batch/repeat/support/ChunkedRepeatTests.java +++ b/spring-batch-infrastructure/src/test/java/org/springframework/batch/repeat/support/ChunkedRepeatTests.java @@ -16,8 +16,8 @@ package org.springframework.batch.repeat.support; +import org.springframework.batch.item.AbstractItemReader; import org.springframework.batch.item.ItemReader; -import org.springframework.batch.item.reader.AbstractItemReader; import org.springframework.batch.repeat.ExitStatus; import org.springframework.batch.repeat.RepeatCallback; import org.springframework.batch.repeat.RepeatContext; diff --git a/spring-batch-infrastructure/src/test/java/org/springframework/batch/repeat/support/Trade.java b/spring-batch-infrastructure/src/test/java/org/springframework/batch/repeat/support/Trade.java index 8c5beec73..ab2c3a9fb 100644 --- a/spring-batch-infrastructure/src/test/java/org/springframework/batch/repeat/support/Trade.java +++ b/spring-batch-infrastructure/src/test/java/org/springframework/batch/repeat/support/Trade.java @@ -18,7 +18,7 @@ package org.springframework.batch.repeat.support; import java.math.BigDecimal; -import org.springframework.batch.io.file.mapping.FieldSet; +import org.springframework.batch.item.file.mapping.FieldSet; /** * @author Rob Harrop diff --git a/spring-batch-infrastructure/src/test/java/org/springframework/batch/retry/callback/ItemReaderRetryCallbackTests.java b/spring-batch-infrastructure/src/test/java/org/springframework/batch/retry/callback/ItemReaderRetryCallbackTests.java index c380337eb..f9ee46689 100644 --- a/spring-batch-infrastructure/src/test/java/org/springframework/batch/retry/callback/ItemReaderRetryCallbackTests.java +++ b/spring-batch-infrastructure/src/test/java/org/springframework/batch/retry/callback/ItemReaderRetryCallbackTests.java @@ -22,7 +22,7 @@ import java.util.List; import junit.framework.TestCase; -import org.springframework.batch.item.writer.AbstractItemWriter; +import org.springframework.batch.item.AbstractItemWriter; import org.springframework.batch.retry.ListItemReaderRecoverer; import org.springframework.batch.retry.RetryContext; import org.springframework.batch.retry.context.RetryContextSupport; diff --git a/spring-batch-infrastructure/src/test/java/org/springframework/batch/retry/policy/ItemReaderRetryPolicyTests.java b/spring-batch-infrastructure/src/test/java/org/springframework/batch/retry/policy/ItemReaderRetryPolicyTests.java index faa7b1fb8..ee2efd483 100644 --- a/spring-batch-infrastructure/src/test/java/org/springframework/batch/retry/policy/ItemReaderRetryPolicyTests.java +++ b/spring-batch-infrastructure/src/test/java/org/springframework/batch/retry/policy/ItemReaderRetryPolicyTests.java @@ -23,11 +23,11 @@ import java.util.List; import junit.framework.TestCase; +import org.springframework.batch.item.AbstractItemWriter; import org.springframework.batch.item.FailedItemIdentifier; import org.springframework.batch.item.ItemKeyGenerator; import org.springframework.batch.item.ItemReader; import org.springframework.batch.item.reader.ListItemReader; -import org.springframework.batch.item.writer.AbstractItemWriter; import org.springframework.batch.repeat.RepeatContext; import org.springframework.batch.repeat.context.RepeatContextSupport; import org.springframework.batch.repeat.synch.RepeatSynchronizationManager; diff --git a/spring-batch-infrastructure/src/test/java/org/springframework/batch/io/support/DefaultPropertEditorRegistrarTests.java b/spring-batch-infrastructure/src/test/java/org/springframework/batch/support/DefaultPropertEditorRegistrarTests.java similarity index 98% rename from spring-batch-infrastructure/src/test/java/org/springframework/batch/io/support/DefaultPropertEditorRegistrarTests.java rename to spring-batch-infrastructure/src/test/java/org/springframework/batch/support/DefaultPropertEditorRegistrarTests.java index 73c4e3d95..ece9989b5 100644 --- a/spring-batch-infrastructure/src/test/java/org/springframework/batch/io/support/DefaultPropertEditorRegistrarTests.java +++ b/spring-batch-infrastructure/src/test/java/org/springframework/batch/support/DefaultPropertEditorRegistrarTests.java @@ -14,7 +14,7 @@ * limitations under the License. */ -package org.springframework.batch.io.support; +package org.springframework.batch.support; import java.util.Collections; import java.util.Properties; diff --git a/spring-batch-infrastructure/src/test/resources/org/springframework/batch/io/cursor/Foo-write.hbm.xml b/spring-batch-infrastructure/src/test/resources/org/springframework/batch/item/database/Foo-write.hbm.xml similarity index 100% rename from spring-batch-infrastructure/src/test/resources/org/springframework/batch/io/cursor/Foo-write.hbm.xml rename to spring-batch-infrastructure/src/test/resources/org/springframework/batch/item/database/Foo-write.hbm.xml diff --git a/spring-batch-infrastructure/src/test/resources/org/springframework/batch/io/cursor/Foo.hbm.xml b/spring-batch-infrastructure/src/test/resources/org/springframework/batch/item/database/Foo.hbm.xml similarity index 100% rename from spring-batch-infrastructure/src/test/resources/org/springframework/batch/io/cursor/Foo.hbm.xml rename to spring-batch-infrastructure/src/test/resources/org/springframework/batch/item/database/Foo.hbm.xml diff --git a/spring-batch-infrastructure/src/test/resources/org/springframework/batch/io/sql/data-source-context.xml b/spring-batch-infrastructure/src/test/resources/org/springframework/batch/item/database/data-source-context.xml similarity index 92% rename from spring-batch-infrastructure/src/test/resources/org/springframework/batch/io/sql/data-source-context.xml rename to spring-batch-infrastructure/src/test/resources/org/springframework/batch/item/database/data-source-context.xml index 083019ae6..4bd3a443c 100644 --- a/spring-batch-infrastructure/src/test/resources/org/springframework/batch/io/sql/data-source-context.xml +++ b/spring-batch-infrastructure/src/test/resources/org/springframework/batch/item/database/data-source-context.xml @@ -9,8 +9,8 @@ - - + + diff --git a/spring-batch-infrastructure/src/test/resources/org/springframework/batch/io/sql/destroy-foo-schema-hsqldb.sql b/spring-batch-infrastructure/src/test/resources/org/springframework/batch/item/database/destroy-foo-schema-hsqldb.sql similarity index 100% rename from spring-batch-infrastructure/src/test/resources/org/springframework/batch/io/sql/destroy-foo-schema-hsqldb.sql rename to spring-batch-infrastructure/src/test/resources/org/springframework/batch/item/database/destroy-foo-schema-hsqldb.sql diff --git a/spring-batch-infrastructure/src/test/resources/org/springframework/batch/io/driving/ibatis-config.xml b/spring-batch-infrastructure/src/test/resources/org/springframework/batch/item/database/ibatis-config.xml similarity index 83% rename from spring-batch-infrastructure/src/test/resources/org/springframework/batch/io/driving/ibatis-config.xml rename to spring-batch-infrastructure/src/test/resources/org/springframework/batch/item/database/ibatis-config.xml index e61d44869..f23807357 100644 --- a/spring-batch-infrastructure/src/test/resources/org/springframework/batch/io/driving/ibatis-config.xml +++ b/spring-batch-infrastructure/src/test/resources/org/springframework/batch/item/database/ibatis-config.xml @@ -7,6 +7,6 @@ to false, input source would load all data into memory! --> - + \ No newline at end of file diff --git a/spring-batch-infrastructure/src/test/resources/org/springframework/batch/io/driving/ibatis-foo.xml b/spring-batch-infrastructure/src/test/resources/org/springframework/batch/item/database/ibatis-foo.xml similarity index 100% rename from spring-batch-infrastructure/src/test/resources/org/springframework/batch/io/driving/ibatis-foo.xml rename to spring-batch-infrastructure/src/test/resources/org/springframework/batch/item/database/ibatis-foo.xml diff --git a/spring-batch-infrastructure/src/test/resources/org/springframework/batch/io/sql/init-foo-schema-hsqldb.sql b/spring-batch-infrastructure/src/test/resources/org/springframework/batch/item/database/init-foo-schema-hsqldb.sql similarity index 100% rename from spring-batch-infrastructure/src/test/resources/org/springframework/batch/io/sql/init-foo-schema-hsqldb.sql rename to spring-batch-infrastructure/src/test/resources/org/springframework/batch/item/database/init-foo-schema-hsqldb.sql diff --git a/spring-batch-infrastructure/src/test/resources/org/springframework/batch/io/file/mapping/bean-wrapper.xml b/spring-batch-infrastructure/src/test/resources/org/springframework/batch/item/file/mapping/bean-wrapper.xml similarity index 70% rename from spring-batch-infrastructure/src/test/resources/org/springframework/batch/io/file/mapping/bean-wrapper.xml rename to spring-batch-infrastructure/src/test/resources/org/springframework/batch/item/file/mapping/bean-wrapper.xml index 29f0dda25..0994fe27d 100644 --- a/spring-batch-infrastructure/src/test/resources/org/springframework/batch/io/file/mapping/bean-wrapper.xml +++ b/spring-batch-infrastructure/src/test/resources/org/springframework/batch/item/file/mapping/bean-wrapper.xml @@ -5,10 +5,10 @@ http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-2.0.xsd"> + class="org.springframework.batch.item.file.mapping.BeanWrapperFieldSetMapper"> - + \ No newline at end of file diff --git a/spring-batch-integration/src/test/java/org/springframework/batch/io/oxm/AbstractStaxEventReaderItemReaderTests.java b/spring-batch-integration/src/test/java/org/springframework/batch/io/oxm/AbstractStaxEventReaderItemReaderTests.java index 378867d80..d68580445 100644 --- a/spring-batch-integration/src/test/java/org/springframework/batch/io/oxm/AbstractStaxEventReaderItemReaderTests.java +++ b/spring-batch-integration/src/test/java/org/springframework/batch/io/oxm/AbstractStaxEventReaderItemReaderTests.java @@ -7,9 +7,9 @@ import java.util.List; import junit.framework.TestCase; import org.springframework.batch.io.oxm.domain.Trade; -import org.springframework.batch.io.xml.StaxEventItemReader; -import org.springframework.batch.io.xml.oxm.UnmarshallingEventReaderDeserializer; import org.springframework.batch.item.ExecutionContext; +import org.springframework.batch.item.xml.StaxEventItemReader; +import org.springframework.batch.item.xml.oxm.UnmarshallingEventReaderDeserializer; import org.springframework.core.io.ClassPathResource; import org.springframework.core.io.Resource; import org.springframework.oxm.Unmarshaller; diff --git a/spring-batch-integration/src/test/java/org/springframework/batch/io/oxm/AbstractStaxEventWriterItemWriterTests.java b/spring-batch-integration/src/test/java/org/springframework/batch/io/oxm/AbstractStaxEventWriterItemWriterTests.java index 091b25b66..a28d0ece0 100644 --- a/spring-batch-integration/src/test/java/org/springframework/batch/io/oxm/AbstractStaxEventWriterItemWriterTests.java +++ b/spring-batch-integration/src/test/java/org/springframework/batch/io/oxm/AbstractStaxEventWriterItemWriterTests.java @@ -12,9 +12,9 @@ import junit.framework.TestCase; import org.custommonkey.xmlunit.XMLAssert; import org.custommonkey.xmlunit.XMLUnit; import org.springframework.batch.io.oxm.domain.Trade; -import org.springframework.batch.io.xml.StaxEventItemWriter; -import org.springframework.batch.io.xml.oxm.MarshallingEventWriterSerializer; import org.springframework.batch.item.ExecutionContext; +import org.springframework.batch.item.xml.StaxEventItemWriter; +import org.springframework.batch.item.xml.oxm.MarshallingEventWriterSerializer; import org.springframework.core.io.ClassPathResource; import org.springframework.core.io.FileSystemResource; import org.springframework.core.io.Resource; diff --git a/spring-batch-integration/src/test/java/org/springframework/batch/jms/ExternalRetryInBatchTests.java b/spring-batch-integration/src/test/java/org/springframework/batch/jms/ExternalRetryInBatchTests.java index d6db012d6..e00be8427 100644 --- a/spring-batch-integration/src/test/java/org/springframework/batch/jms/ExternalRetryInBatchTests.java +++ b/spring-batch-integration/src/test/java/org/springframework/batch/jms/ExternalRetryInBatchTests.java @@ -21,10 +21,10 @@ import java.util.List; import javax.sql.DataSource; +import org.springframework.batch.item.AbstractItemReader; +import org.springframework.batch.item.AbstractItemWriter; import org.springframework.batch.item.ItemReader; import org.springframework.batch.item.ItemRecoverer; -import org.springframework.batch.item.reader.AbstractItemReader; -import org.springframework.batch.item.writer.AbstractItemWriter; import org.springframework.batch.repeat.ExitStatus; import org.springframework.batch.repeat.RepeatCallback; import org.springframework.batch.repeat.RepeatContext; diff --git a/spring-batch-integration/src/test/java/org/springframework/batch/retry/jms/ExternalRetryTests.java b/spring-batch-integration/src/test/java/org/springframework/batch/retry/jms/ExternalRetryTests.java index f63bb6230..0ac861f86 100644 --- a/spring-batch-integration/src/test/java/org/springframework/batch/retry/jms/ExternalRetryTests.java +++ b/spring-batch-integration/src/test/java/org/springframework/batch/retry/jms/ExternalRetryTests.java @@ -21,10 +21,10 @@ import java.util.List; import javax.sql.DataSource; +import org.springframework.batch.item.AbstractItemReader; +import org.springframework.batch.item.AbstractItemWriter; import org.springframework.batch.item.ItemReader; import org.springframework.batch.item.ItemRecoverer; -import org.springframework.batch.item.reader.AbstractItemReader; -import org.springframework.batch.item.writer.AbstractItemWriter; import org.springframework.batch.retry.callback.ItemReaderRetryCallback; import org.springframework.batch.retry.policy.ItemReaderRetryPolicy; import org.springframework.batch.retry.support.RetryTemplate; diff --git a/spring-batch-integration/src/test/java/org/springframework/batch/retry/jms/SynchronousTests.java b/spring-batch-integration/src/test/java/org/springframework/batch/retry/jms/SynchronousTests.java index a2a59e4c8..aeb01fea0 100644 --- a/spring-batch-integration/src/test/java/org/springframework/batch/retry/jms/SynchronousTests.java +++ b/spring-batch-integration/src/test/java/org/springframework/batch/retry/jms/SynchronousTests.java @@ -19,8 +19,8 @@ package org.springframework.batch.retry.jms; import java.util.ArrayList; import java.util.List; +import org.springframework.batch.item.AbstractItemWriter; import org.springframework.batch.item.reader.JmsItemReader; -import org.springframework.batch.item.writer.AbstractItemWriter; import org.springframework.batch.retry.RetryCallback; import org.springframework.batch.retry.RetryContext; import org.springframework.batch.retry.callback.ItemReaderRetryCallback; diff --git a/spring-batch-integration/src/test/java/org/springframework/retry/jms/SynchronousTests.java b/spring-batch-integration/src/test/java/org/springframework/retry/jms/SynchronousTests.java index e21f6a25f..f432dbbd2 100644 --- a/spring-batch-integration/src/test/java/org/springframework/retry/jms/SynchronousTests.java +++ b/spring-batch-integration/src/test/java/org/springframework/retry/jms/SynchronousTests.java @@ -19,8 +19,8 @@ package org.springframework.retry.jms; import java.util.ArrayList; import java.util.List; +import org.springframework.batch.item.AbstractItemWriter; import org.springframework.batch.item.reader.JmsItemReader; -import org.springframework.batch.item.writer.AbstractItemWriter; import org.springframework.batch.retry.RetryCallback; import org.springframework.batch.retry.RetryContext; import org.springframework.batch.retry.callback.ItemReaderRetryCallback; diff --git a/spring-batch-samples/.springBeans b/spring-batch-samples/.springBeans index 94c1edcd2..bc007b60a 100644 --- a/spring-batch-samples/.springBeans +++ b/spring-batch-samples/.springBeans @@ -1,7 +1,7 @@ 1 - + @@ -34,6 +34,7 @@ src/main/resources/jobs/simpleJob.xml src/main/resources/simple-job-launcher-context.xml src/main/resources/jobs/batchUpdateJob.xml + src/test/resources/org/springframework/batch/sample/item/writer/staging-test-context.xml @@ -44,14 +45,6 @@ src/main/resources/data-source-context.xml - - - true - false - - src/main/resources/data-source-context.xml - - true @@ -259,5 +252,14 @@ src/main/resources/simple-job-launcher-context.xml + + + true + false + + src/main/resources/data-source-context.xml + src/test/resources/org/springframework/batch/sample/item/writer/staging-test-context.xml + + diff --git a/spring-batch-samples/src/main/java/org/springframework/batch/sample/FieldSetResultSetExtractor.java b/spring-batch-samples/src/main/java/org/springframework/batch/sample/FieldSetResultSetExtractor.java index 004c754e9..8dab9f64a 100644 --- a/spring-batch-samples/src/main/java/org/springframework/batch/sample/FieldSetResultSetExtractor.java +++ b/spring-batch-samples/src/main/java/org/springframework/batch/sample/FieldSetResultSetExtractor.java @@ -22,8 +22,8 @@ import java.sql.SQLException; import java.util.ArrayList; import java.util.List; -import org.springframework.batch.io.file.mapping.DefaultFieldSet; -import org.springframework.batch.io.file.mapping.FieldSet; +import org.springframework.batch.item.file.mapping.DefaultFieldSet; +import org.springframework.batch.item.file.mapping.FieldSet; /** * ResultSetExtractor implementation that returns list of FieldSets diff --git a/spring-batch-samples/src/main/java/org/springframework/batch/sample/dao/FlatFileOrderWriter.java b/spring-batch-samples/src/main/java/org/springframework/batch/sample/dao/FlatFileOrderWriter.java index aaf8f610a..2e88cdbd0 100644 --- a/spring-batch-samples/src/main/java/org/springframework/batch/sample/dao/FlatFileOrderWriter.java +++ b/spring-batch-samples/src/main/java/org/springframework/batch/sample/dao/FlatFileOrderWriter.java @@ -16,8 +16,8 @@ package org.springframework.batch.sample.dao; +import org.springframework.batch.item.transform.ItemTransformer; import org.springframework.batch.item.writer.DelegatingItemWriter; -import org.springframework.batch.item.writer.ItemTransformer; import org.springframework.batch.sample.item.writer.OrderWriter; diff --git a/spring-batch-samples/src/main/java/org/springframework/batch/sample/dao/OrderTransformer.java b/spring-batch-samples/src/main/java/org/springframework/batch/sample/dao/OrderTransformer.java index 9a05a0a31..d1e3553f9 100644 --- a/spring-batch-samples/src/main/java/org/springframework/batch/sample/dao/OrderTransformer.java +++ b/spring-batch-samples/src/main/java/org/springframework/batch/sample/dao/OrderTransformer.java @@ -21,10 +21,10 @@ import java.util.ArrayList; import java.util.List; import java.util.Map; -import org.springframework.batch.io.file.mapping.DefaultFieldSet; -import org.springframework.batch.io.file.mapping.FieldSet; -import org.springframework.batch.io.file.transform.LineAggregator; -import org.springframework.batch.item.writer.ItemTransformer; +import org.springframework.batch.item.file.mapping.DefaultFieldSet; +import org.springframework.batch.item.file.mapping.FieldSet; +import org.springframework.batch.item.file.transform.LineAggregator; +import org.springframework.batch.item.transform.ItemTransformer; import org.springframework.batch.sample.domain.Address; import org.springframework.batch.sample.domain.BillingInfo; import org.springframework.batch.sample.domain.Customer; diff --git a/spring-batch-samples/src/main/java/org/springframework/batch/sample/item/reader/OrderItemReader.java b/spring-batch-samples/src/main/java/org/springframework/batch/sample/item/reader/OrderItemReader.java index 8449b2b8f..1ea0ca915 100644 --- a/spring-batch-samples/src/main/java/org/springframework/batch/sample/item/reader/OrderItemReader.java +++ b/spring-batch-samples/src/main/java/org/springframework/batch/sample/item/reader/OrderItemReader.java @@ -21,8 +21,8 @@ import java.util.ArrayList; import org.apache.commons.logging.Log; import org.apache.commons.logging.LogFactory; import org.springframework.batch.core.StepExecution; -import org.springframework.batch.io.file.mapping.FieldSet; -import org.springframework.batch.io.file.mapping.FieldSetMapper; +import org.springframework.batch.item.file.mapping.FieldSet; +import org.springframework.batch.item.file.mapping.FieldSetMapper; import org.springframework.batch.item.reader.DelegatingItemReader; import org.springframework.batch.sample.domain.Address; import org.springframework.batch.sample.domain.BillingInfo; diff --git a/spring-batch-samples/src/main/java/org/springframework/batch/sample/item/reader/StagingItemReader.java b/spring-batch-samples/src/main/java/org/springframework/batch/sample/item/reader/StagingItemReader.java index ffd8fda5f..f1ed32cdc 100644 --- a/spring-batch-samples/src/main/java/org/springframework/batch/sample/item/reader/StagingItemReader.java +++ b/spring-batch-samples/src/main/java/org/springframework/batch/sample/item/reader/StagingItemReader.java @@ -53,7 +53,7 @@ public class StagingItemReader extends JdbcDaoSupport implements ItemStream, Ite /** * - * @see org.springframework.batch.io.driving.DrivingQueryItemReader#close(ExecutionContext) + * @see org.springframework.batch.item.database.DrivingQueryItemReader#close(ExecutionContext) */ public void close(ExecutionContext executionContext) { initialized = false; @@ -65,7 +65,7 @@ public class StagingItemReader extends JdbcDaoSupport implements ItemStream, Ite /** * - * @see org.springframework.batch.io.driving.DrivingQueryItemReader#open() + * @see org.springframework.batch.item.database.DrivingQueryItemReader#open() */ public void open(ExecutionContext executionContext) { // Can be called from multiple threads because of lazy initialisation... diff --git a/spring-batch-samples/src/main/java/org/springframework/batch/sample/item/writer/BatchSqlCustomerCreditIncreaseWriter.java b/spring-batch-samples/src/main/java/org/springframework/batch/sample/item/writer/BatchSqlCustomerCreditIncreaseWriter.java index 1dbb55fe4..48b4e5b1b 100644 --- a/spring-batch-samples/src/main/java/org/springframework/batch/sample/item/writer/BatchSqlCustomerCreditIncreaseWriter.java +++ b/spring-batch-samples/src/main/java/org/springframework/batch/sample/item/writer/BatchSqlCustomerCreditIncreaseWriter.java @@ -2,10 +2,10 @@ package org.springframework.batch.sample.item.writer; import java.math.BigDecimal; -import org.springframework.batch.io.support.BatchSqlUpdateItemWriter; import org.springframework.batch.item.ClearFailedException; import org.springframework.batch.item.FlushFailedException; import org.springframework.batch.item.ItemWriter; +import org.springframework.batch.item.database.BatchSqlUpdateItemWriter; import org.springframework.batch.sample.domain.CustomerCredit; import org.springframework.beans.factory.InitializingBean; import org.springframework.util.Assert; @@ -52,7 +52,7 @@ public class BatchSqlCustomerCreditIncreaseWriter implements ItemWriter, Initial /** * @throws ClearFailedException - * @see org.springframework.batch.io.support.BatchSqlUpdateItemWriter#clear() + * @see org.springframework.batch.item.database.BatchSqlUpdateItemWriter#clear() */ public void clear() throws ClearFailedException { delegate.clear(); @@ -60,7 +60,7 @@ public class BatchSqlCustomerCreditIncreaseWriter implements ItemWriter, Initial /** * @throws FlushFailedException - * @see org.springframework.batch.io.support.BatchSqlUpdateItemWriter#flush() + * @see org.springframework.batch.item.database.BatchSqlUpdateItemWriter#flush() */ public void flush() throws FlushFailedException { delegate.flush(); diff --git a/spring-batch-samples/src/main/java/org/springframework/batch/sample/item/writer/CustomerCreditIncreaseWriter.java b/spring-batch-samples/src/main/java/org/springframework/batch/sample/item/writer/CustomerCreditIncreaseWriter.java index 0432cb92e..62947df57 100644 --- a/spring-batch-samples/src/main/java/org/springframework/batch/sample/item/writer/CustomerCreditIncreaseWriter.java +++ b/spring-batch-samples/src/main/java/org/springframework/batch/sample/item/writer/CustomerCreditIncreaseWriter.java @@ -2,7 +2,7 @@ package org.springframework.batch.sample.item.writer; import java.math.BigDecimal; -import org.springframework.batch.item.writer.AbstractItemWriter; +import org.springframework.batch.item.AbstractItemWriter; import org.springframework.batch.sample.dao.CustomerCreditDao; import org.springframework.batch.sample.domain.CustomerCredit; diff --git a/spring-batch-samples/src/main/java/org/springframework/batch/sample/item/writer/CustomerCreditUpdatePreparedStatementSetter.java b/spring-batch-samples/src/main/java/org/springframework/batch/sample/item/writer/CustomerCreditUpdatePreparedStatementSetter.java index 1a69707cf..31378779d 100644 --- a/spring-batch-samples/src/main/java/org/springframework/batch/sample/item/writer/CustomerCreditUpdatePreparedStatementSetter.java +++ b/spring-batch-samples/src/main/java/org/springframework/batch/sample/item/writer/CustomerCreditUpdatePreparedStatementSetter.java @@ -18,7 +18,7 @@ package org.springframework.batch.sample.item.writer; import java.sql.PreparedStatement; import java.sql.SQLException; -import org.springframework.batch.io.support.ItemPreparedStatementSetter; +import org.springframework.batch.item.database.ItemPreparedStatementSetter; import org.springframework.batch.sample.domain.CustomerCredit; /** diff --git a/spring-batch-samples/src/main/java/org/springframework/batch/sample/item/writer/CustomerCreditUpdateWriter.java b/spring-batch-samples/src/main/java/org/springframework/batch/sample/item/writer/CustomerCreditUpdateWriter.java index 109b4c8da..2cea41156 100644 --- a/spring-batch-samples/src/main/java/org/springframework/batch/sample/item/writer/CustomerCreditUpdateWriter.java +++ b/spring-batch-samples/src/main/java/org/springframework/batch/sample/item/writer/CustomerCreditUpdateWriter.java @@ -16,7 +16,7 @@ package org.springframework.batch.sample.item.writer; -import org.springframework.batch.item.writer.AbstractItemWriter; +import org.springframework.batch.item.AbstractItemWriter; import org.springframework.batch.sample.dao.CustomerCreditDao; import org.springframework.batch.sample.domain.CustomerCredit; diff --git a/spring-batch-samples/src/main/java/org/springframework/batch/sample/item/writer/CustomerUpdateWriter.java b/spring-batch-samples/src/main/java/org/springframework/batch/sample/item/writer/CustomerUpdateWriter.java index e0fff68cd..99c33211d 100644 --- a/spring-batch-samples/src/main/java/org/springframework/batch/sample/item/writer/CustomerUpdateWriter.java +++ b/spring-batch-samples/src/main/java/org/springframework/batch/sample/item/writer/CustomerUpdateWriter.java @@ -16,7 +16,7 @@ package org.springframework.batch.sample.item.writer; -import org.springframework.batch.item.writer.AbstractItemWriter; +import org.springframework.batch.item.AbstractItemWriter; import org.springframework.batch.sample.dao.JdbcCustomerDebitDao; import org.springframework.batch.sample.domain.CustomerDebit; import org.springframework.batch.sample.domain.Trade; diff --git a/spring-batch-samples/src/main/java/org/springframework/batch/sample/item/writer/PersonWriter.java b/spring-batch-samples/src/main/java/org/springframework/batch/sample/item/writer/PersonWriter.java index b5517344c..aea45d10a 100644 --- a/spring-batch-samples/src/main/java/org/springframework/batch/sample/item/writer/PersonWriter.java +++ b/spring-batch-samples/src/main/java/org/springframework/batch/sample/item/writer/PersonWriter.java @@ -18,7 +18,7 @@ package org.springframework.batch.sample.item.writer; import org.apache.commons.logging.Log; import org.apache.commons.logging.LogFactory; -import org.springframework.batch.item.writer.AbstractItemWriter; +import org.springframework.batch.item.AbstractItemWriter; import org.springframework.batch.sample.domain.Person; diff --git a/spring-batch-samples/src/main/java/org/springframework/batch/sample/item/writer/PlayerItemWriter.java b/spring-batch-samples/src/main/java/org/springframework/batch/sample/item/writer/PlayerItemWriter.java index 69756708e..253fd8e54 100644 --- a/spring-batch-samples/src/main/java/org/springframework/batch/sample/item/writer/PlayerItemWriter.java +++ b/spring-batch-samples/src/main/java/org/springframework/batch/sample/item/writer/PlayerItemWriter.java @@ -1,6 +1,6 @@ package org.springframework.batch.sample.item.writer; -import org.springframework.batch.item.writer.AbstractItemWriter; +import org.springframework.batch.item.AbstractItemWriter; import org.springframework.batch.sample.dao.PlayerDao; import org.springframework.batch.sample.domain.Player; diff --git a/spring-batch-samples/src/main/java/org/springframework/batch/sample/item/writer/RetrySampleItemWriter.java b/spring-batch-samples/src/main/java/org/springframework/batch/sample/item/writer/RetrySampleItemWriter.java index 58c270855..f56db368f 100644 --- a/spring-batch-samples/src/main/java/org/springframework/batch/sample/item/writer/RetrySampleItemWriter.java +++ b/spring-batch-samples/src/main/java/org/springframework/batch/sample/item/writer/RetrySampleItemWriter.java @@ -1,6 +1,6 @@ package org.springframework.batch.sample.item.writer; -import org.springframework.batch.item.writer.AbstractItemWriter; +import org.springframework.batch.item.AbstractItemWriter; /** * Simulates temporary output trouble - requires to diff --git a/spring-batch-samples/src/main/java/org/springframework/batch/sample/item/writer/TradeWriter.java b/spring-batch-samples/src/main/java/org/springframework/batch/sample/item/writer/TradeWriter.java index 177ad9967..50fcdfe63 100644 --- a/spring-batch-samples/src/main/java/org/springframework/batch/sample/item/writer/TradeWriter.java +++ b/spring-batch-samples/src/main/java/org/springframework/batch/sample/item/writer/TradeWriter.java @@ -18,7 +18,7 @@ package org.springframework.batch.sample.item.writer; import org.apache.commons.logging.Log; import org.apache.commons.logging.LogFactory; -import org.springframework.batch.item.writer.AbstractItemWriter; +import org.springframework.batch.item.AbstractItemWriter; import org.springframework.batch.sample.dao.TradeDao; import org.springframework.batch.sample.domain.Trade; diff --git a/spring-batch-samples/src/main/java/org/springframework/batch/sample/mapping/AddressFieldSetMapper.java b/spring-batch-samples/src/main/java/org/springframework/batch/sample/mapping/AddressFieldSetMapper.java index d2c06b7d4..4c2a4c673 100644 --- a/spring-batch-samples/src/main/java/org/springframework/batch/sample/mapping/AddressFieldSetMapper.java +++ b/spring-batch-samples/src/main/java/org/springframework/batch/sample/mapping/AddressFieldSetMapper.java @@ -16,8 +16,8 @@ package org.springframework.batch.sample.mapping; -import org.springframework.batch.io.file.mapping.FieldSetMapper; -import org.springframework.batch.io.file.mapping.FieldSet; +import org.springframework.batch.item.file.mapping.FieldSet; +import org.springframework.batch.item.file.mapping.FieldSetMapper; import org.springframework.batch.sample.domain.Address; diff --git a/spring-batch-samples/src/main/java/org/springframework/batch/sample/mapping/BillingFieldSetMapper.java b/spring-batch-samples/src/main/java/org/springframework/batch/sample/mapping/BillingFieldSetMapper.java index c546f3bbf..f5bcbeeb0 100644 --- a/spring-batch-samples/src/main/java/org/springframework/batch/sample/mapping/BillingFieldSetMapper.java +++ b/spring-batch-samples/src/main/java/org/springframework/batch/sample/mapping/BillingFieldSetMapper.java @@ -16,8 +16,8 @@ package org.springframework.batch.sample.mapping; -import org.springframework.batch.io.file.mapping.FieldSetMapper; -import org.springframework.batch.io.file.mapping.FieldSet; +import org.springframework.batch.item.file.mapping.FieldSet; +import org.springframework.batch.item.file.mapping.FieldSetMapper; import org.springframework.batch.sample.domain.BillingInfo; diff --git a/spring-batch-samples/src/main/java/org/springframework/batch/sample/mapping/CustomerFieldSetMapper.java b/spring-batch-samples/src/main/java/org/springframework/batch/sample/mapping/CustomerFieldSetMapper.java index 43e9b5f49..d96a4a1ca 100644 --- a/spring-batch-samples/src/main/java/org/springframework/batch/sample/mapping/CustomerFieldSetMapper.java +++ b/spring-batch-samples/src/main/java/org/springframework/batch/sample/mapping/CustomerFieldSetMapper.java @@ -16,8 +16,8 @@ package org.springframework.batch.sample.mapping; -import org.springframework.batch.io.file.mapping.FieldSetMapper; -import org.springframework.batch.io.file.mapping.FieldSet; +import org.springframework.batch.item.file.mapping.FieldSet; +import org.springframework.batch.item.file.mapping.FieldSetMapper; import org.springframework.batch.sample.domain.Customer; diff --git a/spring-batch-samples/src/main/java/org/springframework/batch/sample/mapping/GameMapper.java b/spring-batch-samples/src/main/java/org/springframework/batch/sample/mapping/GameMapper.java index 354f73493..532f5b751 100644 --- a/spring-batch-samples/src/main/java/org/springframework/batch/sample/mapping/GameMapper.java +++ b/spring-batch-samples/src/main/java/org/springframework/batch/sample/mapping/GameMapper.java @@ -1,7 +1,7 @@ package org.springframework.batch.sample.mapping; -import org.springframework.batch.io.file.mapping.FieldSetMapper; -import org.springframework.batch.io.file.mapping.FieldSet; +import org.springframework.batch.item.file.mapping.FieldSet; +import org.springframework.batch.item.file.mapping.FieldSetMapper; import org.springframework.batch.sample.domain.Game; public class GameMapper implements FieldSetMapper { diff --git a/spring-batch-samples/src/main/java/org/springframework/batch/sample/mapping/HeaderFieldSetMapper.java b/spring-batch-samples/src/main/java/org/springframework/batch/sample/mapping/HeaderFieldSetMapper.java index e8e501023..61cbe7924 100644 --- a/spring-batch-samples/src/main/java/org/springframework/batch/sample/mapping/HeaderFieldSetMapper.java +++ b/spring-batch-samples/src/main/java/org/springframework/batch/sample/mapping/HeaderFieldSetMapper.java @@ -16,8 +16,8 @@ package org.springframework.batch.sample.mapping; -import org.springframework.batch.io.file.mapping.FieldSetMapper; -import org.springframework.batch.io.file.mapping.FieldSet; +import org.springframework.batch.item.file.mapping.FieldSet; +import org.springframework.batch.item.file.mapping.FieldSetMapper; import org.springframework.batch.sample.domain.Order; diff --git a/spring-batch-samples/src/main/java/org/springframework/batch/sample/mapping/OrderItemFieldSetMapper.java b/spring-batch-samples/src/main/java/org/springframework/batch/sample/mapping/OrderItemFieldSetMapper.java index a41c1921b..2f35d2474 100644 --- a/spring-batch-samples/src/main/java/org/springframework/batch/sample/mapping/OrderItemFieldSetMapper.java +++ b/spring-batch-samples/src/main/java/org/springframework/batch/sample/mapping/OrderItemFieldSetMapper.java @@ -16,8 +16,8 @@ package org.springframework.batch.sample.mapping; -import org.springframework.batch.io.file.mapping.FieldSetMapper; -import org.springframework.batch.io.file.mapping.FieldSet; +import org.springframework.batch.item.file.mapping.FieldSet; +import org.springframework.batch.item.file.mapping.FieldSetMapper; import org.springframework.batch.sample.domain.LineItem; diff --git a/spring-batch-samples/src/main/java/org/springframework/batch/sample/mapping/PlayerMapper.java b/spring-batch-samples/src/main/java/org/springframework/batch/sample/mapping/PlayerMapper.java index 09f0392e6..51b50aec4 100644 --- a/spring-batch-samples/src/main/java/org/springframework/batch/sample/mapping/PlayerMapper.java +++ b/spring-batch-samples/src/main/java/org/springframework/batch/sample/mapping/PlayerMapper.java @@ -1,7 +1,7 @@ package org.springframework.batch.sample.mapping; -import org.springframework.batch.io.file.mapping.FieldSetMapper; -import org.springframework.batch.io.file.mapping.FieldSet; +import org.springframework.batch.item.file.mapping.FieldSet; +import org.springframework.batch.item.file.mapping.FieldSetMapper; import org.springframework.batch.sample.domain.Player; public class PlayerMapper implements FieldSetMapper { diff --git a/spring-batch-samples/src/main/java/org/springframework/batch/sample/mapping/ShippingFieldSetMapper.java b/spring-batch-samples/src/main/java/org/springframework/batch/sample/mapping/ShippingFieldSetMapper.java index fa1083135..2fc8a6a45 100644 --- a/spring-batch-samples/src/main/java/org/springframework/batch/sample/mapping/ShippingFieldSetMapper.java +++ b/spring-batch-samples/src/main/java/org/springframework/batch/sample/mapping/ShippingFieldSetMapper.java @@ -16,8 +16,8 @@ package org.springframework.batch.sample.mapping; -import org.springframework.batch.io.file.mapping.FieldSetMapper; -import org.springframework.batch.io.file.mapping.FieldSet; +import org.springframework.batch.item.file.mapping.FieldSet; +import org.springframework.batch.item.file.mapping.FieldSetMapper; import org.springframework.batch.sample.domain.ShippingInfo; diff --git a/spring-batch-samples/src/main/java/org/springframework/batch/sample/mapping/TradeFieldSetMapper.java b/spring-batch-samples/src/main/java/org/springframework/batch/sample/mapping/TradeFieldSetMapper.java index 0c90f7f35..a221e9964 100644 --- a/spring-batch-samples/src/main/java/org/springframework/batch/sample/mapping/TradeFieldSetMapper.java +++ b/spring-batch-samples/src/main/java/org/springframework/batch/sample/mapping/TradeFieldSetMapper.java @@ -16,8 +16,8 @@ package org.springframework.batch.sample.mapping; -import org.springframework.batch.io.file.mapping.FieldSetMapper; -import org.springframework.batch.io.file.mapping.FieldSet; +import org.springframework.batch.item.file.mapping.FieldSet; +import org.springframework.batch.item.file.mapping.FieldSetMapper; import org.springframework.batch.item.reader.AggregateItemReader; import org.springframework.batch.sample.domain.Trade; diff --git a/spring-batch-samples/src/main/java/org/springframework/batch/sample/tasklet/SimpleTradeWriter.java b/spring-batch-samples/src/main/java/org/springframework/batch/sample/tasklet/SimpleTradeWriter.java index 710300d01..ef5e012a0 100644 --- a/spring-batch-samples/src/main/java/org/springframework/batch/sample/tasklet/SimpleTradeWriter.java +++ b/spring-batch-samples/src/main/java/org/springframework/batch/sample/tasklet/SimpleTradeWriter.java @@ -17,10 +17,10 @@ package org.springframework.batch.sample.tasklet; import org.springframework.batch.core.tasklet.Tasklet; +import org.springframework.batch.item.AbstractItemWriter; import org.springframework.batch.item.ExecutionContext; import org.springframework.batch.item.ItemStream; import org.springframework.batch.item.ItemStreamException; -import org.springframework.batch.item.writer.AbstractItemWriter; import org.springframework.batch.sample.dao.TradeDao; import org.springframework.batch.sample.domain.Trade; import org.springframework.util.Assert; diff --git a/spring-batch-samples/src/main/resources/jobs/batchUpdateJob.xml b/spring-batch-samples/src/main/resources/jobs/batchUpdateJob.xml index 65f84f1ba..22add10e4 100644 --- a/spring-batch-samples/src/main/resources/jobs/batchUpdateJob.xml +++ b/spring-batch-samples/src/main/resources/jobs/batchUpdateJob.xml @@ -24,7 +24,7 @@ - + @@ -34,7 +34,7 @@ - + diff --git a/spring-batch-samples/src/main/resources/jobs/beanWrapperMapperSampleJob.xml b/spring-batch-samples/src/main/resources/jobs/beanWrapperMapperSampleJob.xml index 2e67792a4..b11657bd8 100644 --- a/spring-batch-samples/src/main/resources/jobs/beanWrapperMapperSampleJob.xml +++ b/spring-batch-samples/src/main/resources/jobs/beanWrapperMapperSampleJob.xml @@ -16,7 +16,7 @@ + class="org.springframework.batch.item.validator.ValidatingItemReader"> + class="org.springframework.batch.item.file.FlatFileItemReader"> + class="org.springframework.batch.item.file.FlatFileItemReader"> @@ -61,13 +61,13 @@ + class="org.springframework.batch.item.file.transform.FixedLengthTokenizer"> + class="org.springframework.batch.item.file.transform.FixedLengthTokenizer"> + class="org.springframework.batch.item.file.mapping.BeanWrapperFieldSetMapper"> + class="org.springframework.batch.item.file.mapping.BeanWrapperFieldSetMapper"> diff --git a/spring-batch-samples/src/main/resources/jobs/compositeProcessorSampleJob.xml b/spring-batch-samples/src/main/resources/jobs/compositeProcessorSampleJob.xml index 5e006e4b7..495a35b0e 100644 --- a/spring-batch-samples/src/main/resources/jobs/compositeProcessorSampleJob.xml +++ b/spring-batch-samples/src/main/resources/jobs/compositeProcessorSampleJob.xml @@ -15,7 +15,7 @@ + class="org.springframework.batch.item.validator.ValidatingItemReader"> @@ -42,14 +42,14 @@ + class="org.springframework.batch.item.file.FlatFileItemReader"> + class="org.springframework.batch.item.file.transform.FixedLengthTokenizer"> @@ -81,12 +81,12 @@ - + class="org.springframework.batch.item.file.mapping.PassThroughFieldSetMapper" /> diff --git a/spring-batch-samples/src/main/resources/jobs/fixedLengthImportJob.xml b/spring-batch-samples/src/main/resources/jobs/fixedLengthImportJob.xml index 8f33f3467..c7d040a88 100644 --- a/spring-batch-samples/src/main/resources/jobs/fixedLengthImportJob.xml +++ b/spring-batch-samples/src/main/resources/jobs/fixedLengthImportJob.xml @@ -15,7 +15,7 @@ + class="org.springframework.batch.item.validator.ValidatingItemReader"> @@ -35,7 +35,7 @@ + class="org.springframework.batch.item.file.FlatFileItemReader"> @@ -45,7 +45,7 @@ autowire-candidate="false"/> + class="org.springframework.batch.item.file.transform.FixedLengthTokenizer"> diff --git a/spring-batch-samples/src/main/resources/jobs/footballJob.xml b/spring-batch-samples/src/main/resources/jobs/footballJob.xml index 5053c8c2c..1034948fb 100644 --- a/spring-batch-samples/src/main/resources/jobs/footballJob.xml +++ b/spring-batch-samples/src/main/resources/jobs/footballJob.xml @@ -59,12 +59,12 @@ + class="org.springframework.batch.item.file.FlatFileItemReader"> + class="org.springframework.batch.item.file.transform.DelimitedLineTokenizer"> @@ -76,12 +76,12 @@ + class="org.springframework.batch.item.file.FlatFileItemReader"> + class="org.springframework.batch.item.file.transform.DelimitedLineTokenizer"> @@ -93,7 +93,7 @@ + class="org.springframework.batch.item.database.JdbcCursorItemReader"> + class="org.springframework.batch.item.database.HibernateAwareItemWriter"> @@ -43,7 +43,7 @@ + class="org.springframework.batch.item.database.HibernateCursorItemReader"> diff --git a/spring-batch-samples/src/main/resources/jobs/ibatisJob.xml b/spring-batch-samples/src/main/resources/jobs/ibatisJob.xml index 056f1bbc8..c636f81ff 100644 --- a/spring-batch-samples/src/main/resources/jobs/ibatisJob.xml +++ b/spring-batch-samples/src/main/resources/jobs/ibatisJob.xml @@ -34,14 +34,14 @@ + class="org.springframework.batch.item.database.IbatisDrivingQueryItemReader"> + class="org.springframework.batch.item.database.support.IbatisKeyGenerator"> diff --git a/spring-batch-samples/src/main/resources/jobs/multilineJob.xml b/spring-batch-samples/src/main/resources/jobs/multilineJob.xml index f0e772b64..5699be80c 100644 --- a/spring-batch-samples/src/main/resources/jobs/multilineJob.xml +++ b/spring-batch-samples/src/main/resources/jobs/multilineJob.xml @@ -20,11 +20,11 @@ + class="org.springframework.batch.item.file.FlatFileItemWriter"> - + @@ -33,7 +33,7 @@ + class="org.springframework.batch.item.file.FlatFileItemReader"> @@ -45,7 +45,7 @@ class="org.springframework.batch.sample.mapping.TradeFieldSetMapper" /> + class="org.springframework.batch.item.file.transform.PrefixMatchingCompositeLineTokenizer"> @@ -56,17 +56,17 @@ + class="org.springframework.batch.item.file.transform.FixedLengthTokenizer"> + class="org.springframework.batch.item.file.transform.FixedLengthTokenizer"> + class="org.springframework.batch.item.file.transform.FixedLengthTokenizer"> diff --git a/spring-batch-samples/src/main/resources/jobs/multilineOrderInputDescriptors.xml b/spring-batch-samples/src/main/resources/jobs/multilineOrderInputDescriptors.xml index 5341c7967..550e93a07 100644 --- a/spring-batch-samples/src/main/resources/jobs/multilineOrderInputDescriptors.xml +++ b/spring-batch-samples/src/main/resources/jobs/multilineOrderInputDescriptors.xml @@ -4,7 +4,7 @@ http://www.springframework.org/schema/beans/spring-beans-2.0.xsd"> + class="org.springframework.batch.item.file.transform.PrefixMatchingCompositeLineTokenizer"> @@ -22,12 +22,12 @@ + class="org.springframework.batch.item.file.transform.FixedLengthTokenizer"> + class="org.springframework.batch.item.file.transform.DelimitedLineTokenizer"> diff --git a/spring-batch-samples/src/main/resources/jobs/multilineOrderIo.xml b/spring-batch-samples/src/main/resources/jobs/multilineOrderIo.xml index 2bf3edd23..f616ce6c0 100644 --- a/spring-batch-samples/src/main/resources/jobs/multilineOrderIo.xml +++ b/spring-batch-samples/src/main/resources/jobs/multilineOrderIo.xml @@ -9,37 +9,37 @@ http://www.springframework.org/schema/aop/spring-aop-2.0.xsd"> + class="org.springframework.batch.item.file.FlatFileItemReader"> + class="org.springframework.batch.item.file.mapping.PassThroughFieldSetMapper" /> + class="org.springframework.batch.item.transform.ItemTransformerItemWriter"> + class="org.springframework.batch.item.file.transform.RecursiveCollectionItemTransformer" /> + class="org.springframework.batch.item.file.FlatFileItemWriter"> + class="org.springframework.batch.item.file.mapping.PassThroughFieldSetMapper" /> + class="org.springframework.batch.item.file.transform.DelimitedLineTokenizer" /> + class="org.springframework.batch.item.file.transform.FixedLengthLineAggregator" /> \ No newline at end of file diff --git a/spring-batch-samples/src/main/resources/jobs/multilineOrderJob.xml b/spring-batch-samples/src/main/resources/jobs/multilineOrderJob.xml index 40f8e8876..a2f229857 100644 --- a/spring-batch-samples/src/main/resources/jobs/multilineOrderJob.xml +++ b/spring-batch-samples/src/main/resources/jobs/multilineOrderJob.xml @@ -22,7 +22,7 @@ + class="org.springframework.batch.item.validator.ValidatingItemReader"> diff --git a/spring-batch-samples/src/main/resources/jobs/multilineOrderOutputDescriptors.xml b/spring-batch-samples/src/main/resources/jobs/multilineOrderOutputDescriptors.xml index 1a1e813ad..2542cbbc8 100644 --- a/spring-batch-samples/src/main/resources/jobs/multilineOrderOutputDescriptors.xml +++ b/spring-batch-samples/src/main/resources/jobs/multilineOrderOutputDescriptors.xml @@ -14,26 +14,26 @@ - - \ No newline at end of file diff --git a/spring-batch-samples/src/main/resources/jobs/parallelJob.xml b/spring-batch-samples/src/main/resources/jobs/parallelJob.xml index 7b853ff0a..3681d69ac 100644 --- a/spring-batch-samples/src/main/resources/jobs/parallelJob.xml +++ b/spring-batch-samples/src/main/resources/jobs/parallelJob.xml @@ -18,7 +18,7 @@ + class="org.springframework.batch.item.validator.ValidatingItemReader"> + class="org.springframework.batch.item.file.FlatFileItemReader"> @@ -81,7 +81,7 @@ + class="org.springframework.batch.item.file.transform.FixedLengthTokenizer"> diff --git a/spring-batch-samples/src/main/resources/jobs/restartSample.xml b/spring-batch-samples/src/main/resources/jobs/restartSample.xml index 0eb1e5a8c..4117c08e4 100644 --- a/spring-batch-samples/src/main/resources/jobs/restartSample.xml +++ b/spring-batch-samples/src/main/resources/jobs/restartSample.xml @@ -15,7 +15,7 @@ + class="org.springframework.batch.item.validator.ValidatingItemReader"> @@ -40,14 +40,14 @@ + class="org.springframework.batch.item.file.FlatFileItemReader"> + class="org.springframework.batch.item.file.transform.FixedLengthTokenizer"> diff --git a/spring-batch-samples/src/main/resources/jobs/rollbackJob.xml b/spring-batch-samples/src/main/resources/jobs/rollbackJob.xml index 2d181f4c1..764c8fbc4 100644 --- a/spring-batch-samples/src/main/resources/jobs/rollbackJob.xml +++ b/spring-batch-samples/src/main/resources/jobs/rollbackJob.xml @@ -19,7 +19,7 @@ + class="org.springframework.batch.item.validator.ValidatingItemReader"> + class="org.springframework.batch.item.database.JdbcCursorItemReader"> @@ -56,7 +56,7 @@ + class="org.springframework.batch.item.database.JdbcCursorItemReader"> diff --git a/spring-batch-samples/src/main/resources/jobs/simpleJob.xml b/spring-batch-samples/src/main/resources/jobs/simpleJob.xml index 04ab3d459..e738cb0e3 100644 --- a/spring-batch-samples/src/main/resources/jobs/simpleJob.xml +++ b/spring-batch-samples/src/main/resources/jobs/simpleJob.xml @@ -36,7 +36,7 @@ + class="org.springframework.batch.item.file.FlatFileItemReader"> @@ -55,7 +55,7 @@ + class="org.springframework.batch.item.file.transform.FixedLengthTokenizer"> diff --git a/spring-batch-samples/src/main/resources/jobs/tradeJob.xml b/spring-batch-samples/src/main/resources/jobs/tradeJob.xml index ee38c431f..c38096b46 100644 --- a/spring-batch-samples/src/main/resources/jobs/tradeJob.xml +++ b/spring-batch-samples/src/main/resources/jobs/tradeJob.xml @@ -17,7 +17,7 @@ + class="org.springframework.batch.item.validator.ValidatingItemReader"> + class="org.springframework.batch.item.database.JdbcCursorItemReader"> @@ -64,7 +64,7 @@ + class="org.springframework.batch.item.database.JdbcCursorItemReader"> diff --git a/spring-batch-samples/src/main/resources/jobs/tradeJobIo.xml b/spring-batch-samples/src/main/resources/jobs/tradeJobIo.xml index cc5e73010..337600d9f 100644 --- a/spring-batch-samples/src/main/resources/jobs/tradeJobIo.xml +++ b/spring-batch-samples/src/main/resources/jobs/tradeJobIo.xml @@ -27,18 +27,18 @@ id="customerReportOutputSource"> + class="org.springframework.batch.item.file.mapping.PassThroughFieldSetMapper" /> - @@ -49,7 +49,7 @@ + class="org.springframework.batch.item.file.transform.DelimitedLineTokenizer"> diff --git a/spring-batch-samples/src/main/resources/jobs/xmlStaxJob.xml b/spring-batch-samples/src/main/resources/jobs/xmlStaxJob.xml index ef108d7dd..4de6a1140 100644 --- a/spring-batch-samples/src/main/resources/jobs/xmlStaxJob.xml +++ b/spring-batch-samples/src/main/resources/jobs/xmlStaxJob.xml @@ -16,14 +16,14 @@ + class="org.springframework.batch.item.xml.StaxEventItemReader"> + class="org.springframework.batch.item.xml.oxm.UnmarshallingEventReaderDeserializer"> @@ -40,7 +40,7 @@ - @@ -50,7 +50,7 @@ - - + + diff --git a/spring-batch-samples/src/test/java/org/springframework/batch/sample/FixedLengthImportJobFunctionalTests.java b/spring-batch-samples/src/test/java/org/springframework/batch/sample/FixedLengthImportJobFunctionalTests.java index a1ad23597..1ce1232e2 100644 --- a/spring-batch-samples/src/test/java/org/springframework/batch/sample/FixedLengthImportJobFunctionalTests.java +++ b/spring-batch-samples/src/test/java/org/springframework/batch/sample/FixedLengthImportJobFunctionalTests.java @@ -21,9 +21,9 @@ import java.io.FileReader; import java.sql.ResultSet; import java.sql.SQLException; -import org.springframework.batch.io.file.FlatFileItemReader; -import org.springframework.batch.io.file.transform.LineTokenizer; import org.springframework.batch.item.ExecutionContext; +import org.springframework.batch.item.file.FlatFileItemReader; +import org.springframework.batch.item.file.transform.LineTokenizer; import org.springframework.batch.sample.domain.Trade; import org.springframework.batch.sample.mapping.TradeFieldSetMapper; import org.springframework.core.io.ClassPathResource; diff --git a/spring-batch-samples/src/test/java/org/springframework/batch/sample/StubLineAggregator.java b/spring-batch-samples/src/test/java/org/springframework/batch/sample/StubLineAggregator.java index c6a1f7fc2..a64bd0653 100644 --- a/spring-batch-samples/src/test/java/org/springframework/batch/sample/StubLineAggregator.java +++ b/spring-batch-samples/src/test/java/org/springframework/batch/sample/StubLineAggregator.java @@ -16,8 +16,8 @@ package org.springframework.batch.sample; -import org.springframework.batch.io.file.mapping.FieldSet; -import org.springframework.batch.io.file.transform.LineAggregator; +import org.springframework.batch.item.file.mapping.FieldSet; +import org.springframework.batch.item.file.transform.LineAggregator; /** diff --git a/spring-batch-samples/src/test/java/org/springframework/batch/sample/dao/FlatFileOrderWriterTests.java b/spring-batch-samples/src/test/java/org/springframework/batch/sample/dao/FlatFileOrderWriterTests.java index dd6bc38e9..2770b1eb2 100644 --- a/spring-batch-samples/src/test/java/org/springframework/batch/sample/dao/FlatFileOrderWriterTests.java +++ b/spring-batch-samples/src/test/java/org/springframework/batch/sample/dao/FlatFileOrderWriterTests.java @@ -9,9 +9,9 @@ import java.util.Map; import junit.framework.TestCase; -import org.springframework.batch.io.file.transform.LineAggregator; +import org.springframework.batch.item.AbstractItemWriter; import org.springframework.batch.item.ItemWriter; -import org.springframework.batch.item.writer.AbstractItemWriter; +import org.springframework.batch.item.file.transform.LineAggregator; import org.springframework.batch.sample.StubLineAggregator; import org.springframework.batch.sample.domain.Address; import org.springframework.batch.sample.domain.BillingInfo; diff --git a/spring-batch-samples/src/test/java/org/springframework/batch/sample/dao/OrderTransformerTests.java b/spring-batch-samples/src/test/java/org/springframework/batch/sample/dao/OrderTransformerTests.java index 2aca10451..567526c81 100644 --- a/spring-batch-samples/src/test/java/org/springframework/batch/sample/dao/OrderTransformerTests.java +++ b/spring-batch-samples/src/test/java/org/springframework/batch/sample/dao/OrderTransformerTests.java @@ -23,7 +23,7 @@ import java.util.HashMap; import junit.framework.TestCase; -import org.springframework.batch.io.file.transform.DelimitedLineAggregator; +import org.springframework.batch.item.file.transform.DelimitedLineAggregator; import org.springframework.batch.sample.domain.Address; import org.springframework.batch.sample.domain.BillingInfo; import org.springframework.batch.sample.domain.Customer; diff --git a/spring-batch-samples/src/test/java/org/springframework/batch/sample/item/reader/OrderItemReaderTests.java b/spring-batch-samples/src/test/java/org/springframework/batch/sample/item/reader/OrderItemReaderTests.java index 798cfaf16..7f15e3b4f 100644 --- a/spring-batch-samples/src/test/java/org/springframework/batch/sample/item/reader/OrderItemReaderTests.java +++ b/spring-batch-samples/src/test/java/org/springframework/batch/sample/item/reader/OrderItemReaderTests.java @@ -5,10 +5,10 @@ import java.util.Iterator; import junit.framework.TestCase; import org.easymock.MockControl; -import org.springframework.batch.io.file.mapping.DefaultFieldSet; -import org.springframework.batch.io.file.mapping.FieldSet; -import org.springframework.batch.io.file.mapping.FieldSetMapper; import org.springframework.batch.item.ItemReader; +import org.springframework.batch.item.file.mapping.DefaultFieldSet; +import org.springframework.batch.item.file.mapping.FieldSet; +import org.springframework.batch.item.file.mapping.FieldSetMapper; import org.springframework.batch.sample.domain.Address; import org.springframework.batch.sample.domain.BillingInfo; import org.springframework.batch.sample.domain.Customer; diff --git a/spring-batch-samples/src/test/java/org/springframework/batch/sample/mapping/AbstractFieldSetMapperTests.java b/spring-batch-samples/src/test/java/org/springframework/batch/sample/mapping/AbstractFieldSetMapperTests.java index a88139ee8..8f9ddd3c2 100644 --- a/spring-batch-samples/src/test/java/org/springframework/batch/sample/mapping/AbstractFieldSetMapperTests.java +++ b/spring-batch-samples/src/test/java/org/springframework/batch/sample/mapping/AbstractFieldSetMapperTests.java @@ -1,7 +1,7 @@ package org.springframework.batch.sample.mapping; -import org.springframework.batch.io.file.mapping.FieldSet; -import org.springframework.batch.io.file.mapping.FieldSetMapper; +import org.springframework.batch.item.file.mapping.FieldSet; +import org.springframework.batch.item.file.mapping.FieldSetMapper; import junit.framework.TestCase; diff --git a/spring-batch-samples/src/test/java/org/springframework/batch/sample/mapping/AddressFieldSetMapperTests.java b/spring-batch-samples/src/test/java/org/springframework/batch/sample/mapping/AddressFieldSetMapperTests.java index 8a89fc941..7937c9bbb 100644 --- a/spring-batch-samples/src/test/java/org/springframework/batch/sample/mapping/AddressFieldSetMapperTests.java +++ b/spring-batch-samples/src/test/java/org/springframework/batch/sample/mapping/AddressFieldSetMapperTests.java @@ -1,8 +1,8 @@ package org.springframework.batch.sample.mapping; -import org.springframework.batch.io.file.mapping.DefaultFieldSet; -import org.springframework.batch.io.file.mapping.FieldSet; -import org.springframework.batch.io.file.mapping.FieldSetMapper; +import org.springframework.batch.item.file.mapping.DefaultFieldSet; +import org.springframework.batch.item.file.mapping.FieldSet; +import org.springframework.batch.item.file.mapping.FieldSetMapper; import org.springframework.batch.sample.domain.Address; import org.springframework.batch.sample.mapping.AddressFieldSetMapper; diff --git a/spring-batch-samples/src/test/java/org/springframework/batch/sample/mapping/BillingFieldSetMapperTests.java b/spring-batch-samples/src/test/java/org/springframework/batch/sample/mapping/BillingFieldSetMapperTests.java index 3a1d251fd..85a298f2d 100644 --- a/spring-batch-samples/src/test/java/org/springframework/batch/sample/mapping/BillingFieldSetMapperTests.java +++ b/spring-batch-samples/src/test/java/org/springframework/batch/sample/mapping/BillingFieldSetMapperTests.java @@ -1,8 +1,8 @@ package org.springframework.batch.sample.mapping; -import org.springframework.batch.io.file.mapping.DefaultFieldSet; -import org.springframework.batch.io.file.mapping.FieldSet; -import org.springframework.batch.io.file.mapping.FieldSetMapper; +import org.springframework.batch.item.file.mapping.DefaultFieldSet; +import org.springframework.batch.item.file.mapping.FieldSet; +import org.springframework.batch.item.file.mapping.FieldSetMapper; import org.springframework.batch.sample.domain.BillingInfo; public class BillingFieldSetMapperTests extends AbstractFieldSetMapperTests{ diff --git a/spring-batch-samples/src/test/java/org/springframework/batch/sample/mapping/CustomerFieldSetMapperTests.java b/spring-batch-samples/src/test/java/org/springframework/batch/sample/mapping/CustomerFieldSetMapperTests.java index e66a0b4d6..921f055ed 100644 --- a/spring-batch-samples/src/test/java/org/springframework/batch/sample/mapping/CustomerFieldSetMapperTests.java +++ b/spring-batch-samples/src/test/java/org/springframework/batch/sample/mapping/CustomerFieldSetMapperTests.java @@ -1,8 +1,8 @@ package org.springframework.batch.sample.mapping; -import org.springframework.batch.io.file.mapping.DefaultFieldSet; -import org.springframework.batch.io.file.mapping.FieldSet; -import org.springframework.batch.io.file.mapping.FieldSetMapper; +import org.springframework.batch.item.file.mapping.DefaultFieldSet; +import org.springframework.batch.item.file.mapping.FieldSet; +import org.springframework.batch.item.file.mapping.FieldSetMapper; import org.springframework.batch.sample.domain.Customer; import org.springframework.batch.sample.mapping.CustomerFieldSetMapper; diff --git a/spring-batch-samples/src/test/java/org/springframework/batch/sample/mapping/HeaderFieldSetMapperTests.java b/spring-batch-samples/src/test/java/org/springframework/batch/sample/mapping/HeaderFieldSetMapperTests.java index 3ec5946b0..635cd9af4 100644 --- a/spring-batch-samples/src/test/java/org/springframework/batch/sample/mapping/HeaderFieldSetMapperTests.java +++ b/spring-batch-samples/src/test/java/org/springframework/batch/sample/mapping/HeaderFieldSetMapperTests.java @@ -2,9 +2,9 @@ package org.springframework.batch.sample.mapping; import java.util.Calendar; -import org.springframework.batch.io.file.mapping.DefaultFieldSet; -import org.springframework.batch.io.file.mapping.FieldSet; -import org.springframework.batch.io.file.mapping.FieldSetMapper; +import org.springframework.batch.item.file.mapping.DefaultFieldSet; +import org.springframework.batch.item.file.mapping.FieldSet; +import org.springframework.batch.item.file.mapping.FieldSetMapper; import org.springframework.batch.sample.domain.Order; public class HeaderFieldSetMapperTests extends AbstractFieldSetMapperTests { diff --git a/spring-batch-samples/src/test/java/org/springframework/batch/sample/mapping/OrderItemFieldSetMapperTests.java b/spring-batch-samples/src/test/java/org/springframework/batch/sample/mapping/OrderItemFieldSetMapperTests.java index 7b44dc18b..a05c3a2d6 100644 --- a/spring-batch-samples/src/test/java/org/springframework/batch/sample/mapping/OrderItemFieldSetMapperTests.java +++ b/spring-batch-samples/src/test/java/org/springframework/batch/sample/mapping/OrderItemFieldSetMapperTests.java @@ -2,9 +2,9 @@ package org.springframework.batch.sample.mapping; import java.math.BigDecimal; -import org.springframework.batch.io.file.mapping.DefaultFieldSet; -import org.springframework.batch.io.file.mapping.FieldSet; -import org.springframework.batch.io.file.mapping.FieldSetMapper; +import org.springframework.batch.item.file.mapping.DefaultFieldSet; +import org.springframework.batch.item.file.mapping.FieldSet; +import org.springframework.batch.item.file.mapping.FieldSetMapper; import org.springframework.batch.sample.domain.LineItem; public class OrderItemFieldSetMapperTests extends AbstractFieldSetMapperTests{ diff --git a/spring-batch-samples/src/test/java/org/springframework/batch/sample/mapping/ShippingFieldSetMapperTests.java b/spring-batch-samples/src/test/java/org/springframework/batch/sample/mapping/ShippingFieldSetMapperTests.java index fe46e002a..9d0f36e40 100644 --- a/spring-batch-samples/src/test/java/org/springframework/batch/sample/mapping/ShippingFieldSetMapperTests.java +++ b/spring-batch-samples/src/test/java/org/springframework/batch/sample/mapping/ShippingFieldSetMapperTests.java @@ -1,8 +1,8 @@ package org.springframework.batch.sample.mapping; -import org.springframework.batch.io.file.mapping.DefaultFieldSet; -import org.springframework.batch.io.file.mapping.FieldSet; -import org.springframework.batch.io.file.mapping.FieldSetMapper; +import org.springframework.batch.item.file.mapping.DefaultFieldSet; +import org.springframework.batch.item.file.mapping.FieldSet; +import org.springframework.batch.item.file.mapping.FieldSetMapper; import org.springframework.batch.sample.domain.ShippingInfo; import org.springframework.batch.sample.mapping.ShippingFieldSetMapper; diff --git a/spring-batch-samples/src/test/java/org/springframework/batch/sample/mapping/TradeFieldSetMapperTests.java b/spring-batch-samples/src/test/java/org/springframework/batch/sample/mapping/TradeFieldSetMapperTests.java index c3f341945..dbe18729d 100644 --- a/spring-batch-samples/src/test/java/org/springframework/batch/sample/mapping/TradeFieldSetMapperTests.java +++ b/spring-batch-samples/src/test/java/org/springframework/batch/sample/mapping/TradeFieldSetMapperTests.java @@ -2,9 +2,9 @@ package org.springframework.batch.sample.mapping; import java.math.BigDecimal; -import org.springframework.batch.io.file.mapping.DefaultFieldSet; -import org.springframework.batch.io.file.mapping.FieldSet; -import org.springframework.batch.io.file.mapping.FieldSetMapper; +import org.springframework.batch.item.file.mapping.DefaultFieldSet; +import org.springframework.batch.item.file.mapping.FieldSet; +import org.springframework.batch.item.file.mapping.FieldSetMapper; import org.springframework.batch.item.reader.AggregateItemReader; import org.springframework.batch.sample.domain.Trade; import org.springframework.batch.sample.mapping.TradeFieldSetMapper; diff --git a/spring-batch-samples/src/test/java/org/springframework/batch/sample/tasklet/SimpleTradeTaskletTests.java b/spring-batch-samples/src/test/java/org/springframework/batch/sample/tasklet/SimpleTradeTaskletTests.java index 9d6a78698..1b75ae0a6 100644 --- a/spring-batch-samples/src/test/java/org/springframework/batch/sample/tasklet/SimpleTradeTaskletTests.java +++ b/spring-batch-samples/src/test/java/org/springframework/batch/sample/tasklet/SimpleTradeTaskletTests.java @@ -4,7 +4,7 @@ import java.math.BigDecimal; import junit.framework.TestCase; -import org.springframework.batch.io.file.FlatFileItemReader; +import org.springframework.batch.item.file.FlatFileItemReader; import org.springframework.batch.sample.dao.TradeDao; import org.springframework.batch.sample.domain.Trade;