11/*
2- * Copyright 2002-2022 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.
3535import org .springframework .core .Ordered ;
3636import org .springframework .util .Assert ;
3737
38- import static org .springframework .batch .support .MethodInvokerUtils .getMethodInvokerByAnnotation ;
39- import static org .springframework .batch .support .MethodInvokerUtils .getMethodInvokerForInterface ;
40-
4138/**
4239 * {@link FactoryBean} implementation that builds a listener based on the various
4340 * lifecycle methods or annotations that are provided. There are three possible ways of
6158 *
6259 * @author Lucas Ward
6360 * @author Dan Garrette
61+ * @author Taeik Lim
6462 * @since 2.0
6563 * @see ListenerMetaData
6664 */
@@ -98,8 +96,8 @@ public Object getObject() {
9896 Set <MethodInvoker > invokers = new HashSet <>();
9997
10098 MethodInvoker invoker ;
101- invoker = getMethodInvokerForInterface (metaData .getListenerInterface (), metaData . getMethodName (), delegate ,
102- metaData .getParamTypes ());
99+ invoker = MethodInvokerUtils . getMethodInvokerForInterface (metaData .getListenerInterface (),
100+ metaData .getMethodName (), delegate , metaData . getParamTypes ());
103101 if (invoker != null ) {
104102 invokers .add (invoker );
105103 }
@@ -111,7 +109,8 @@ public Object getObject() {
111109 }
112110
113111 if (metaData .getAnnotation () != null ) {
114- invoker = getMethodInvokerByAnnotation (metaData .getAnnotation (), delegate , metaData .getParamTypes ());
112+ invoker = MethodInvokerUtils .getMethodInvokerByAnnotation (metaData .getAnnotation (), delegate ,
113+ metaData .getParamTypes ());
115114 if (invoker != null ) {
116115 invokers .add (invoker );
117116 synthetic = true ;
0 commit comments