Annotation Type Path


@Target(TYPE)
@Retention(RUNTIME)
public @interface Path
Specify the path mapping request to the controller.


  @Controller
  @Path("/customers")
  class CustomerController {
    ...
  }

 

JAX-RS note

Note that unlike JAX-RS we only use @Path on the controller type and don't use it on the methods. This is because the @Get, @Post etc annotations include a path as well.

  • Required Element Summary

    Required Elements
    Modifier and Type Required Element Description
    String value