UML Modeling Guide

Stereotype «BeanParam»

Stereotype «BeanParam»

Stereotype «BeanParam» is used to mark a class or parameter as so called bean parameter. Bean parameters can be used to group REST parameters together.

This has mainly two benefits:

  • Instead of defining the same set of parameters for every REST operation over and over again you can just use the bean parameter instead. This is a great help to keep the parameters of your REST services consistent among all operations.

  • When it comes to code generation for Java service interfaces the bean parameter class is used as parameter of the operation instead of the individual parameters. This helps to have clearer interfaces and also ensure a better maintainability

Stereotype «BeanParam» on classes makes only sense when at least one of the attributes of the class is marked as REST parameter (stereotypes «PathParam», «HeaderParam», «QueryParam», «CookieParam»)


Stereotype «BeanParam»  
Applicable Elements Class Parameter  
Tagged Values    
Name Type Description
inline Boolean Property defines if the bean param should be generated inline in an OpenAPI specification or if it should be represented there as explicit type.

By default bean params will be inlined.
supportsCustomHeaders Boolean Besides defining headers explicitly it is also possible to mark a bean param to support custom headers. This means that the generated Java class will have a Map to store arbitrary header fields.


For further information please refer to:


Generated by JEAF Generator