Class AbstractContainerDefinitionBuilder<R extends ContainerDefinition,T extends AbstractContainerDefinitionBuilder<R,T>>
java.lang.Object
com._1c.g5.aef2.standard.definitions.builders.AbstractBuilder<R,T>
com._1c.g5.aef2.standard.definitions.builders.AbstractContainerDefinitionBuilder<R,T>
- Type Parameters:
R- the container definition type.T- the type of the builder.
- Direct Known Subclasses:
DtGranularEditorPageSingleColumnBuilder,ManagingDefinitionBuilder,SectionDefinitionBuilder
public abstract class AbstractContainerDefinitionBuilder<R extends ContainerDefinition,T extends AbstractContainerDefinitionBuilder<R,T>>
extends AbstractBuilder<R,T>
The
AbstractBuilder for ContainerDefinition successors.-
Constructor Summary
ConstructorsModifierConstructorDescriptionprotectedAbstractContainerDefinitionBuilder(Supplier<R> provider) Initializes a builder. -
Method Summary
Modifier and TypeMethodDescriptionprotected intReturns the index of a child definition where the builder is positioned and increment its position.protected intReturns the index of a child definition where the builder is positioned.protected Tinsert(Supplier<? extends IDefinition> definitionProvider) Inserts the definition provided withdefinitionProviderin current position and increment the position.protected voidsetPosition(int index) Sets the current position to the given.Methods inherited from class com._1c.g5.aef2.standard.definitions.builders.AbstractBuilder
apply, build, self
-
Constructor Details
-
AbstractContainerDefinitionBuilder
Initializes a builder.- Parameters:
provider- the provider of object to build, cannot benull.
-
-
Method Details
-
insert
Inserts the definition provided withdefinitionProviderin current position and increment the position.- Parameters:
definitionProvider- the provider of definition.- Returns:
- the builder instance.
-
getPosition
protected int getPosition()Returns the index of a child definition where the builder is positioned.- Returns:
- the position.
-
getAndIncrementPosition
protected int getAndIncrementPosition()Returns the index of a child definition where the builder is positioned and increment its position.- Returns:
- the position.
-
setPosition
protected void setPosition(int index) Sets the current position to the given.- Parameters:
index- the current position.
-