001package io.avaje.http.api;
002
003import java.lang.annotation.Retention;
004import java.lang.annotation.Target;
005
006import static java.lang.annotation.ElementType.FIELD;
007import static java.lang.annotation.ElementType.PARAMETER;
008import static java.lang.annotation.RetentionPolicy.RUNTIME;
009
010/**
011 * Marks a method parameter to be a query parameter.
012 */
013@Target(value={PARAMETER,FIELD})
014@Retention(value=RUNTIME)
015public @interface QueryParam {
016
017  /**
018   * The name of the query parameter.
019   * <p>
020   * If left blank the method parameter name is used.
021   * </p>
022   * <p>
023   * We typically use this when the query parameter uses snake-case or similar
024   * that does not map to a valid java/kotlin parameter name.
025   * </p>
026   */
027  String value() default "";
028
029}