Class JavaMethodDeclaration.Builder
java.lang.Object
io.spring.initializr.generator.language.java.JavaMethodDeclaration.Builder
- Enclosing class:
- JavaMethodDeclaration
Builder for creating a
JavaMethodDeclaration
.-
Method Summary
Modifier and TypeMethodDescriptionSets the body.modifiers
(int modifiers) Sets the modifiers.parameters
(Parameter... parameters) Sets the parameters.Sets the return type.
-
Method Details
-
modifiers
Sets the modifiers.- Parameters:
modifiers
- the modifiers- Returns:
- this for method chaining
-
returning
Sets the return type.- Parameters:
returnType
- the return type- Returns:
- this for method chaining
-
parameters
Sets the parameters.- Parameters:
parameters
- the parameters- Returns:
- this for method chaining
-
body
Sets the body.- Parameters:
code
- the code for the body- Returns:
- the method containing the body
-