注释类型 NotificationListener


  • @Target(METHOD)
    @Retention(RUNTIME)
    @Inherited
    @Documented
    @Repeatable(List.class)
    public @interface NotificationListener
    订阅通知。
    • 必需元素概要

      所需元素 
      修饰符和类型 必需的元素 说明
      java.lang.Class<?> notification
      要监听的通知类。
    • 可选元素概要

      可选元素 
      修饰符和类型 可选元素 说明
      java.lang.String name
      监听器的名称。
    • 元素详细资料

      • notification

        java.lang.Class<?> notification
        要监听的通知类。
      • name

        java.lang.String name
        监听器的名称。
        默认值:
        ""