接口 ContextConsumer<C extends org.springframework.context.ApplicationContext>

  • 类型参数:
    C - the application context type
    函数接口:
    这是一个函数接口, 因此可用作 lambda 表达式或方法引用的赋值目标。

    @FunctionalInterface
    public interface ContextConsumer<C extends org.springframework.context.ApplicationContext>
    Callback interface used to process an ApplicationContext with the ability to throw a (checked) exception.
    从以下版本开始:
    2.0.0
    另请参阅:
    AbstractApplicationContextRunner
    • 方法概要

      所有方法 实例方法 抽象方法 
      修饰符和类型方法说明
      voidaccept​(C context)
      Performs this operation on the supplied context.
    • 方法详细资料

      • accept

        void accept​(C context)
             throws Throwable
        Performs this operation on the supplied context.
        参数:
        context - the application context to consume
        抛出:
        Throwable - any exception that might occur in assertions