注释类型 InjectService


  • @Target(METHOD)
    @Retention(RUNTIME)
    public @interface InjectService
    Annotation to allow services to request injection of other services
    作者:
    Steve Ebersole
    • 可选元素概要

      可选元素 
      修饰符和类型 可选元素 说明
      boolean required
      Is the service to be injected required (not optional)?
      Class serviceRole
      The service role to inject, the default is to use the type of the parameter to which this method is attached.
    • 元素详细资料

      • serviceRole

        Class serviceRole
        The service role to inject, the default is to use the type of the parameter to which this method is attached.
        返回:
        The service role.
        默认值:
        java.lang.Void.class
      • required

        boolean required
        Is the service to be injected required (not optional)?
        返回:
        True if the service is required.
        默认值:
        true