Annotation Interface PathRemainder


REST request path remainder annotation.

Identifies a POJO to be used as the path remainder (the part after the path match) on an HTTP request.

This is a specialized shortcut for @Path("/*").

Can be used in the following locations:

  • Arguments and argument-types of server-side @RestOp-annotated methods.
  • Arguments and argument-types of client-side @RemoteResource-annotated interfaces.
  • Methods and return types of server-side and client-side @Request-annotated interfaces.
Arguments and argument-types of server-side @RestOp-annotated methods

Annotation that can be applied to a parameter of a @RestOp-annotated method to identify it as the path remainder after the path pattern match.

Example:

@RestGet("/myurl/{foo}/{bar}/*") public void doGet( @Path("foo") String foo, @Path("bar") int bar, @PathRemainder String remainder, // Equivalent to @Path("/*") ) {...}

This is functionally equivalent to using @Path("/*"), but provides a more intuitive name.

See Also:
Arguments and argument-types of client-side @RemoteResource-annotated interfaces

Annotation applied to Java method arguments of interface proxies to denote that they represent the path remainder on the request.

See Also:
Methods and return types of server-side and client-side @Request-annotated interfaces

See Also:
See Also:
Since:
9.2.0
  • Element Details

    • def

      Default value for this parameter.
      Returns:
      The annotation value.
      Default:
      ""
    • description

      Optional description for the exposed API.
      Returns:
      The annotation value.
      Default:
      {}
    • on

      Dynamically apply this annotation to the specified classes.
      See Also:
      Returns:
      The annotation value.
      Default:
      {}
    • onClass

      Dynamically apply this annotation to the specified classes.

      Identical to on() except allows you to specify class objects instead of a strings.

      See Also:
      Returns:
      The annotation value.
      Default:
      {}
    • parser

      Specifies the HttpPartParser class used for parsing strings to values.

      Overrides for this part the part parser defined on the REST resource which by default is OpenApiParser.

      Returns:
      The annotation value.
      Default:
      org.apache.juneau.httppart.HttpPartParser.Void.class
    • schema

      schema field of the Swagger Parameter Object.

      The schema defining the type used for parameter.

      The @Schema annotation can also be used standalone on the parameter or type. Values specified on this field override values specified on the type, and values specified on child types override values specified on parent types.

      Used for:
      • Server-side schema-based parsing and parsing validation.
      • Server-side generated Swagger documentation.
      • Client-side schema-based serializing and serializing validation.
      Returns:
      The annotation value.
      Default:
      @org.apache.juneau.annotation.Schema
    • serializer

      Specifies the HttpPartSerializer class used for serializing values to strings.

      Overrides for this part the part serializer defined on the REST client which by default is OpenApiSerializer.

      Returns:
      The annotation value.
      Default:
      org.apache.juneau.httppart.HttpPartSerializer.Void.class