Class ConfigurationTransformation.VersionedBuilder
java.lang.Object
ninja.leaping.configurate.transformation.ConfigurationTransformation.VersionedBuilder
- Enclosing class:
- ConfigurationTransformation
public static final class ConfigurationTransformation.VersionedBuilder extends Object
Builds a versioned
ConfigurationTransformation
.-
Constructor Summary
Constructors Modifier Constructor Description protected
VersionedBuilder()
-
Method Summary
Modifier and Type Method Description @NonNull ConfigurationTransformation.VersionedBuilder
addVersion(int version, @NonNull ConfigurationTransformation transformation)
Adds a transformation to this builder for the given version.@NonNull ConfigurationTransformation
build()
Builds the transformation.@NonNull ConfigurationTransformation.VersionedBuilder
setVersionKey(@NonNull Object... versionKey)
Sets the path of the version key within the configuration.
-
Constructor Details
-
VersionedBuilder
protected VersionedBuilder()
-
-
Method Details
-
setVersionKey
public @NonNull ConfigurationTransformation.VersionedBuilder setVersionKey(@NonNull Object... versionKey)Sets the path of the version key within the configuration.- Parameters:
versionKey
- The path to the version key- Returns:
- This builder (for chaining)
-
addVersion
public @NonNull ConfigurationTransformation.VersionedBuilder addVersion(int version, @NonNull ConfigurationTransformation transformation)Adds a transformation to this builder for the given version.- Parameters:
version
- The versiontransformation
- The transformation- Returns:
- This builder (for chaining)
-
build
Builds the transformation.- Returns:
- The transformation
-