Class SetupDefinitionBuilder<R extends AbstractDefinition,T extends SetupDefinitionBuilder<R,T,B>,B extends AbstractBuilder<?,B>>
- java.lang.Object
-
- com._1c.g5.aef2.standard.definitions.builders.AbstractBuilder<R,T>
-
- com._1c.g5.aef2.standard.definitions.builders.SetupDefinitionBuilder<R,T,B>
-
- Type Parameters:
R
- the definition type.T
- the type of the builder.B
- the type of builder that is returned after this builder ends setup.
- Direct Known Subclasses:
DtSetupDefinitionBuilder
public class SetupDefinitionBuilder<R extends AbstractDefinition,T extends SetupDefinitionBuilder<R,T,B>,B extends AbstractBuilder<?,B>> extends AbstractBuilder<R,T>
The definition builder that allows to setup the given definition instance.
-
-
Constructor Summary
Constructors Modifier Constructor Description protected
SetupDefinitionBuilder(Supplier<R> provider, B builder)
Initializes a builder.
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static <R extends AbstractDefinition,B extends AbstractBuilder<?,B>>
SetupDefinitionBuilder<R,?,B>builder(Supplier<R> definitionProvider, B builder)
Creates a new builder instance.T
component(Class<? extends IComponent> componentClass, IParameterization parameterization)
Sets the class of component and corresponding parameterization.T
componentFactory(IComponentFactory factory)
Sets a factory that will be used to directly obtain a component.B
endSetup()
Ends the setup of the definition.T
layoutData(IAefLayoutData layoutData)
Sets the layout data object.T
modelFactory(IModelFactory modelFactory)
Sets the model factory.-
Methods inherited from class com._1c.g5.aef2.standard.definitions.builders.AbstractBuilder
apply, build, self
-
-
-
-
Method Detail
-
builder
public static <R extends AbstractDefinition,B extends AbstractBuilder<?,B>> SetupDefinitionBuilder<R,?,B> builder(Supplier<R> definitionProvider, B builder)
Creates a new builder instance.- Parameters:
definitionProvider
- the provider of definition to setup, cannot benull
.builder
- a builder that is returned after this builder ends setup.- Returns:
- the builder instance.
-
layoutData
public T layoutData(IAefLayoutData layoutData)
Sets the layout data object.- Parameters:
layoutData
- the layout data.- Returns:
- the builder instance.
-
modelFactory
public T modelFactory(IModelFactory modelFactory)
Sets the model factory.- Parameters:
modelFactory
- the model factory instance.- Returns:
- the builder instance.
-
component
public T component(Class<? extends IComponent> componentClass, IParameterization parameterization)
Sets the class of component and corresponding parameterization.- Parameters:
componentClass
- the class of component.- Returns:
- the builder instance.
-
componentFactory
public T componentFactory(IComponentFactory factory)
Sets a factory that will be used to directly obtain a component.- Parameters:
factory
- the factory- Returns:
- this
-
endSetup
public B endSetup()
Ends the setup of the definition.- Returns:
- the original builder.
-
-