001package io.avaje.http.api; 002 003import java.lang.annotation.Retention; 004import java.lang.annotation.Target; 005 006import static java.lang.annotation.ElementType.TYPE; 007import static java.lang.annotation.RetentionPolicy.RUNTIME; 008 009/** 010 * Specify the path mapping request to the controller. 011 * 012 * <pre>{@code 013 * 014 * @Controller 015 * @Path("/customers") 016 * class CustomerController { 017 * ... 018 * } 019 * 020 * }</pre> 021 * 022 * <h4>JAX-RS note</h4> 023 * <p> 024 * Note that unlike JAX-RS we only use <code>@Path</code> on the controller type and don't 025 * use it on the methods. This is because the <code>@Get, @Post etc</code> annotations 026 * include a path as well. 027 * </p> 028 */ 029@Target(value=TYPE) 030@Retention(value=RUNTIME) 031public @interface Path { 032 String value(); 033}