Details

    Description

      Introduce a new annotation to specify the parameter name, indicate if it is optional, and potentially support specifying default values in the future.

      Deprecate the argumentNames method in FunctionHints as it is not user-friendly for specifying argument names with optional configuration.

       

      public @interface ArgumentHint {
          /**
           * The name of the parameter, default is an empty string.
           */
          String name() default "";
       
          /**
           * Whether the parameter is optional, default is false.
           */
          boolean isOptional() default false;
       
          /**
           * The data type hint for the parameter.
           */
          DataTypeHint type() default @DataTypeHint();
      }
      
      public @interface FunctionHint {
        
          /**
           * Deprecated attribute for specifying the names of the arguments.
           * It is no longer recommended to use this attribute.
           */
          @Deprecated
          String[] argumentNames() default {""};
        
          /**
           * Attribute for specifying the hints and additional information for function arguments.
           */
          ArgumentHint[] arguments() default {};
      }
      

      Attachments

        Issue Links

          Activity

            People

              hackergin Feng Jin
              hackergin Feng Jin
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: