public class ParameterGroupDeclarer<D extends ParameterGroupDeclaration> extends Declarer<D> implements HasModelProperties<ParameterGroupDeclarer<D>>, HasDisplayModelDeclarer<ParameterGroupDeclarer<D>>
ParameterGroupDeclaration
through a fluent APIdeclaration
Constructor and Description |
---|
ParameterGroupDeclarer(D declaration)
Creates a new instance
|
Modifier and Type | Method and Description |
---|---|
ParameterGroupDeclarer<D> |
withDisplayModel(DisplayModel displayModel)
Sets the given
displayModel |
ParameterGroupDeclarer<D> |
withDslInlineRepresentation(boolean showInDsl)
Sets the DSL representation type to be either inline, where the group
is represented as a child element, or implicit, where the group
is shown as a set of attributes in the element.
|
ParameterGroupDeclarer<D> |
withExclusiveOptionals(Set<String> parameterNames,
boolean requiresOne) |
ParameterGroupDeclarer<D> |
withLayout(LayoutModel layoutModel)
Sets the given
layoutModel |
ParameterGroupDeclarer<D> |
withModelProperty(ModelProperty modelProperty)
Adds the given
modelProperty |
OptionalParameterDeclarer |
withOptionalParameter(String name)
Adds an optional parameter
|
ParameterDeclarer |
withRequiredParameter(String name)
Adds a required parameter
|
getDeclaration
public ParameterGroupDeclarer(D declaration)
declaration
- a declarationpublic ParameterDeclarer withRequiredParameter(String name)
name
- the name of the parameterParameterDeclarer
public OptionalParameterDeclarer withOptionalParameter(String name)
name
- the name of the parameterOptionalParameterDeclarer
public ParameterGroupDeclarer<D> withExclusiveOptionals(Set<String> parameterNames, boolean requiresOne)
public ParameterGroupDeclarer<D> withDslInlineRepresentation(boolean showInDsl)
showInDsl
- true
if the group is shown in the DSLthis
ParameterGroupDeclarer
public ParameterGroupDeclarer<D> withLayout(LayoutModel layoutModel)
layoutModel
layoutModel
- a LayoutModel
this
declarerpublic ParameterGroupDeclarer<D> withModelProperty(ModelProperty modelProperty)
modelProperty
withModelProperty
in interface HasModelProperties<ParameterGroupDeclarer<D extends ParameterGroupDeclaration>>
modelProperty
- a ModelProperty
this
declarerpublic ParameterGroupDeclarer<D> withDisplayModel(DisplayModel displayModel)
displayModel
withDisplayModel
in interface HasDisplayModelDeclarer<ParameterGroupDeclarer<D extends ParameterGroupDeclaration>>
displayModel
- a DisplayModel
this
declarerCopyright © 2018. All rights reserved.