Interface AutowiredArguments

Functional Interface:
This is a functional interface and can therefore be used as the assignment target for a lambda expression or method reference.

@FunctionalInterface public interface AutowiredArguments
Resolved arguments to be autowired.
Since:
6.0
Author:
Phillip Webb, Stephane Nicoll
See Also:
  • Method Summary

    Modifier and Type
    Method
    Description
    default <T> @Nullable T
    get(int index)
    Return the resolved argument at the specified index.
    default <T> @Nullable T
    get(int index, Class<T> requiredType)
    Return the resolved argument at the specified index.
    getObject(int index)
    Return the resolved argument at the specified index.
    of(Object[] arguments)
    Factory method to create a new AutowiredArguments instance from the given object array.
    Return the arguments as an object array.
  • Method Details

    • get

      default <T> @Nullable T get(int index, Class<T> requiredType)
      Return the resolved argument at the specified index.
      Type Parameters:
      T - the type of the argument
      Parameters:
      index - the argument index
      requiredType - the required argument type
      Returns:
      the argument
    • get

      default <T> @Nullable T get(int index)
      Return the resolved argument at the specified index.
      Type Parameters:
      T - the type of the argument
      Parameters:
      index - the argument index
      Returns:
      the argument
    • getObject

      default @Nullable Object getObject(int index)
      Return the resolved argument at the specified index.
      Parameters:
      index - the argument index
      Returns:
      the argument
    • toArray

      Object[] toArray()
      Return the arguments as an object array.
      Returns:
      the arguments as an object array
    • of

      static AutowiredArguments of(Object[] arguments)
      Factory method to create a new AutowiredArguments instance from the given object array.
      Parameters:
      arguments - the arguments
      Returns:
      a new AutowiredArguments instance