Package org.spongepowered.api.world
Interface LocatableBlock.Builder
- All Superinterfaces:
AbstractBuilder<LocatableBlock>,Builder<LocatableBlock,,LocatableBlock.Builder> CopyableBuilder<LocatableBlock,,LocatableBlock.Builder> DataBuilder<LocatableBlock>,ResettableBuilder<LocatableBlock,LocatableBlock.Builder>
- Enclosing interface:
LocatableBlock
public static interface LocatableBlock.Builder
extends Builder<LocatableBlock,LocatableBlock.Builder>, CopyableBuilder<LocatableBlock,LocatableBlock.Builder>, DataBuilder<LocatableBlock>
-
Method Summary
Modifier and TypeMethodDescriptionbuild()Creates a newLocatableBlock.from(LocatableBlock value) Resets this builder to the values of the given built object.location(ServerLocation location) Sets theBlockStateandpositionfor this builder.position(int x, int y, int z) Sets thexyzpositions for this builder.Sets thepositionfor this builder.reset()Resets this builder to a "default" state such that there is no remaining data to set.state(BlockState blockState) Sets theBlockStatefor this builder.world(ServerWorld world) Sets theworldfor this builder, used to get theBlockStatefor a desired position.Methods inherited from interface org.spongepowered.api.data.persistence.DataBuilder
build
-
Method Details
-
state
Sets theBlockStatefor this builder.- Parameters:
blockState- The block state- Returns:
- This builder, for chaining
-
location
Sets theBlockStateandpositionfor this builder.- Parameters:
location- The location containing the block state and position- Returns:
- This builder, for chaining
-
position
Sets thepositionfor this builder.- Parameters:
position- The position- Returns:
- This builder, for chaining
-
position
Sets thexyzpositions for this builder.- Parameters:
x- The x coordinatey- The y coordinatez- The z coordinate- Returns:
- This builder, for chaining
-
world
Sets theworldfor this builder, used to get theBlockStatefor a desired position.- Parameters:
world- The world- Returns:
- This builder, for chaining
-
reset
LocatableBlock.Builder reset()Description copied from interface:BuilderResets this builder to a "default" state such that there is no remaining data to set. This is to be the presumed "default" state.- Specified by:
resetin interfaceBuilder<LocatableBlock,LocatableBlock.Builder> - Specified by:
resetin interfaceResettableBuilder<LocatableBlock,LocatableBlock.Builder> - Returns:
- This builder, for chaining
-
from
Description copied from interface:CopyableBuilderResets this builder to the values of the given built object.- Specified by:
fromin interfaceCopyableBuilder<LocatableBlock,LocatableBlock.Builder> - Parameters:
value- The built object- Returns:
- This builder, for chaining
-
build
LocatableBlock build()Creates a newLocatableBlock.- Specified by:
buildin interfaceAbstractBuilder<LocatableBlock>- Returns:
- The new locatable block
-