Skip to content

Commit fb18040

Browse files
acktsapfmbenhassine
authored andcommitted
Make util classes to follow style guide
Signed-off-by: Taeik Lim <sibera21@gmail.com> Issue #4545
1 parent 376d848 commit fb18040

File tree

10 files changed

+54
-20
lines changed

10 files changed

+54
-20
lines changed

spring-batch-core/src/main/java/org/springframework/batch/core/configuration/xml/BeanDefinitionUtils.java

+6-2
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
* Copyright 2006-2007 the original author or authors.
2+
* Copyright 2006-2024 the original author or authors.
33
*
44
* Licensed under the Apache License, Version 2.0 (the "License");
55
* you may not use this file except in compliance with the License.
@@ -21,9 +21,13 @@
2121

2222
/**
2323
* @author Dan Garrette
24+
* @author Taeik Lim
2425
* @since 2.0.1
2526
*/
26-
public class BeanDefinitionUtils {
27+
public abstract class BeanDefinitionUtils {
28+
29+
private BeanDefinitionUtils() {
30+
}
2731

2832
/**
2933
* @param beanName a bean definition name

spring-batch-core/src/main/java/org/springframework/batch/core/configuration/xml/CoreNamespaceUtils.java

+6-2
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
* Copyright 2006-2023 the original author or authors.
2+
* Copyright 2006-2024 the original author or authors.
33
*
44
* Licensed under the Apache License, Version 2.0 (the "License");
55
* you may not use this file except in compliance with the License.
@@ -37,8 +37,12 @@
3737
* @author Thomas Risberg
3838
* @author Michael Minella
3939
* @author Mahmoud Ben Hassine
40+
* @author Taeik Lim
4041
*/
41-
public class CoreNamespaceUtils {
42+
public abstract class CoreNamespaceUtils {
43+
44+
private CoreNamespaceUtils() {
45+
}
4246

4347
private static final String STEP_SCOPE_PROCESSOR_BEAN_NAME = "org.springframework.batch.core.scope.internalStepScope";
4448

spring-batch-infrastructure/src/main/java/org/springframework/batch/item/database/JdbcParameterUtils.java

+6-2
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
* Copyright 2002-2023 the original author or authors.
2+
* Copyright 2002-2024 the original author or authors.
33
*
44
* Licensed under the Apache License, Version 2.0 (the "License");
55
* you may not use this file except in compliance with the License.
@@ -28,9 +28,13 @@
2828
* @author Thomas Risberg
2929
* @author Juergen Hoeller
3030
* @author Marten Deinum
31+
* @author Taeik Lim
3132
* @since 2.0
3233
*/
33-
public class JdbcParameterUtils {
34+
public abstract class JdbcParameterUtils {
35+
36+
private JdbcParameterUtils() {
37+
}
3438

3539
/**
3640
* Count the occurrences of the character placeholder in an SQL string

spring-batch-infrastructure/src/main/java/org/springframework/batch/item/database/support/SqlPagingQueryUtils.java

+6-2
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
* Copyright 2006-2023 the original author or authors.
2+
* Copyright 2006-2024 the original author or authors.
33
*
44
* Licensed under the Apache License, Version 2.0 (the "License");
55
* you may not use this file except in compliance with the License.
@@ -31,9 +31,13 @@
3131
* @author Dave Syer
3232
* @author Michael Minella
3333
* @author Mahmoud Ben Hassine
34+
* @author Taeik Lim
3435
* @since 2.0
3536
*/
36-
public class SqlPagingQueryUtils {
37+
public abstract class SqlPagingQueryUtils {
38+
39+
private SqlPagingQueryUtils() {
40+
}
3741

3842
/**
3943
* Generate SQL query string using a LIMIT clause

spring-batch-infrastructure/src/main/java/org/springframework/batch/item/util/FileUtils.java

+3-2
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
* Copyright 2006-2021 the original author or authors.
2+
* Copyright 2006-2024 the original author or authors.
33
*
44
* Licensed under the Apache License, Version 2.0 (the "License");
55
* you may not use this file except in compliance with the License.
@@ -27,8 +27,9 @@
2727
*
2828
* @author Peter Zozom
2929
* @author Mahmoud Ben Hassine
30+
* @author Taeik Lim
3031
*/
31-
public final class FileUtils {
32+
public abstract class FileUtils {
3233

3334
// forbids instantiation
3435
private FileUtils() {

spring-batch-infrastructure/src/main/java/org/springframework/batch/support/MethodInvokerUtils.java

+6-2
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
* Copyright 2002-2023 the original author or authors.
2+
* Copyright 2002-2024 the original author or authors.
33
*
44
* Licensed under the Apache License, Version 2.0 (the "License");
55
* you may not use this file except in compliance with the License.
@@ -34,9 +34,13 @@
3434
*
3535
* @author Lucas Ward
3636
* @author Mahmoud Ben Hassine
37+
* @author Taeik Lim
3738
* @since 2.0
3839
*/
39-
public class MethodInvokerUtils {
40+
public abstract class MethodInvokerUtils {
41+
42+
private MethodInvokerUtils() {
43+
}
4044

4145
/**
4246
* Create a {@link MethodInvoker} using the provided method name to search.

spring-batch-infrastructure/src/main/java/org/springframework/batch/support/ReflectionUtils.java

+3-2
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
* Copyright 2014-2023 the original author or authors.
2+
* Copyright 2014-2024 the original author or authors.
33
*
44
* Licensed under the Apache License, Version 2.0 (the "License");
55
* you may not use this file except in compliance with the License.
@@ -29,9 +29,10 @@
2929
*
3030
* @author Michael Minella
3131
* @author Mahmoud Ben Hassine
32+
* @author Taeik Lim
3233
* @since 2.2.6
3334
*/
34-
public class ReflectionUtils {
35+
public abstract class ReflectionUtils {
3536

3637
private ReflectionUtils() {
3738
}

spring-batch-test/src/main/java/org/springframework/batch/test/ExecutionContextTestUtils.java

+6-2
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
* Copyright 2006-2018 the original author or authors.
2+
* Copyright 2006-2024 the original author or authors.
33
*
44
* Licensed under the Apache License, Version 2.0 (the "License");
55
* you may not use this file except in compliance with the License.
@@ -30,10 +30,14 @@
3030
*
3131
* @author Dave Syer
3232
* @author Mahmoud Ben Hassine
33+
* @author Taeik Lim
3334
* @since 2.1.4
3435
*
3536
*/
36-
public class ExecutionContextTestUtils {
37+
public abstract class ExecutionContextTestUtils {
38+
39+
private ExecutionContextTestUtils() {
40+
}
3741

3842
@SuppressWarnings("unchecked")
3943
@Nullable

spring-batch-test/src/main/java/org/springframework/batch/test/JobScopeTestUtils.java

+6-2
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
* Copyright 2006-2023 the original author or authors.
2+
* Copyright 2006-2024 the original author or authors.
33
*
44
* Licensed under the Apache License, Version 2.0 (the "License");
55
* you may not use this file except in compliance with the License.
@@ -29,8 +29,12 @@
2929
* @author Dave Syer
3030
* @author Jimmy Praet
3131
* @author Mahmoud Ben Hassine
32+
* @author Taeik Lim
3233
*/
33-
public class JobScopeTestUtils {
34+
public abstract class JobScopeTestUtils {
35+
36+
private JobScopeTestUtils() {
37+
}
3438

3539
public static <T> T doInJobScope(JobExecution jobExecution, Callable<T> callable) throws Exception {
3640
try {

spring-batch-test/src/main/java/org/springframework/batch/test/StepScopeTestUtils.java

+6-2
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
* Copyright 2006-2010 the original author or authors.
2+
* Copyright 2006-2024 the original author or authors.
33
*
44
* Licensed under the Apache License, Version 2.0 (the "License");
55
* you may not use this file except in compliance with the License.
@@ -27,9 +27,13 @@
2727
* test case that happen to be step scoped in the application context.
2828
*
2929
* @author Dave Syer
30+
* @author Taeik Lim
3031
*
3132
*/
32-
public class StepScopeTestUtils {
33+
public abstract class StepScopeTestUtils {
34+
35+
private StepScopeTestUtils() {
36+
}
3337

3438
public static <T> T doInStepScope(StepExecution stepExecution, Callable<T> callable) throws Exception {
3539
try {

0 commit comments

Comments
 (0)