Revert to more convenient signature in FunctionCatalog
This commit is contained in:
@@ -43,7 +43,7 @@ public interface FunctionCatalog {
|
||||
* @param name the name of the functional interface. Must not be null;
|
||||
* @return instance of the functional interface registered with this catalog
|
||||
*/
|
||||
<T> T lookup(Class<T> type, String name);
|
||||
<T> T lookup(Class<?> type, String name);
|
||||
|
||||
Set<String> getNames(Class<?> type);
|
||||
|
||||
|
||||
@@ -118,7 +118,7 @@ public class InMemoryFunctionCatalog
|
||||
|
||||
@Override
|
||||
@SuppressWarnings("unchecked")
|
||||
public <T> T lookup(Class<T> type, String name) {
|
||||
public <T> T lookup(Class<?> type, String name) {
|
||||
T function = null;
|
||||
if (type == null) {
|
||||
function = (T) functions.values().stream().filter(map -> map.get(name) != null).map(map -> map.get(name)).findFirst().orElse(null);
|
||||
|
||||
@@ -119,7 +119,7 @@ public class ContextFunctionCatalogAutoConfiguration {
|
||||
|
||||
@Override
|
||||
@SuppressWarnings("unchecked")
|
||||
public <T> T lookup(Class<T> type, String name) {
|
||||
public <T> T lookup(Class<?> type, String name) {
|
||||
T function = null;
|
||||
if (type == null) {
|
||||
function = (T) processor.lookupFunction(name);
|
||||
|
||||
Reference in New Issue
Block a user