001/* 002 * Copyright 2002-2015 the original author or authors. 003 * 004 * Licensed under the Apache License, Version 2.0 (the "License"); 005 * you may not use this file except in compliance with the License. 006 * You may obtain a copy of the License at 007 * 008 * https://www.apache.org/licenses/LICENSE-2.0 009 * 010 * Unless required by applicable law or agreed to in writing, software 011 * distributed under the License is distributed on an "AS IS" BASIS, 012 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 013 * See the License for the specific language governing permissions and 014 * limitations under the License. 015 */ 016 017package org.springframework.web.method; 018 019import java.lang.reflect.Method; 020import java.util.Set; 021 022import org.springframework.core.MethodIntrospector; 023import org.springframework.util.ReflectionUtils.MethodFilter; 024 025/** 026 * Defines the algorithm for searching handler methods exhaustively including interfaces and parent 027 * classes while also dealing with parameterized methods as well as interface and class-based proxies. 028 * 029 * @author Rossen Stoyanchev 030 * @since 3.1 031 * @deprecated as of Spring 4.2.3, in favor of the generalized and refined {@link MethodIntrospector} 032 */ 033@Deprecated 034public abstract class HandlerMethodSelector { 035 036 /** 037 * Select handler methods for the given handler type. 038 * <p>Callers define handler methods of interest through the {@link MethodFilter} parameter. 039 * @param handlerType the handler type to search handler methods on 040 * @param handlerMethodFilter a {@link MethodFilter} to help recognize handler methods of interest 041 * @return the selected methods, or an empty set 042 * @see MethodIntrospector#selectMethods 043 */ 044 public static Set<Method> selectMethods(Class<?> handlerType, MethodFilter handlerMethodFilter) { 045 return MethodIntrospector.selectMethods(handlerType, handlerMethodFilter); 046 } 047 048}