Class GsonConfigurationLoader.Builder
- java.lang.Object
-
- org.spongepowered.configurate.loader.AbstractConfigurationLoader.Builder<GsonConfigurationLoader.Builder,GsonConfigurationLoader>
-
- org.spongepowered.configurate.gson.GsonConfigurationLoader.Builder
-
- Enclosing class:
- GsonConfigurationLoader
public static final class GsonConfigurationLoader.Builder extends org.spongepowered.configurate.loader.AbstractConfigurationLoader.Builder<GsonConfigurationLoader.Builder,GsonConfigurationLoader>
Builds aGsonConfigurationLoader
.- Since:
- 4.0.0
-
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description @NonNull GsonConfigurationLoader
build()
int
indent()
Gets the level of indentation to be used by the resultant loader.@NonNull GsonConfigurationLoader.Builder
indent(int indent)
Sets the level of indentation the resultant loader should use.boolean
lenient()
Gets if the resultant loader should parse leniently.@NonNull GsonConfigurationLoader.Builder
lenient(boolean lenient)
Sets if the resultant loader should parse leniently.
-
-
-
Method Detail
-
indent
public @NonNull GsonConfigurationLoader.Builder indent(int indent)
Sets the level of indentation the resultant loader should use.- Parameters:
indent
- the indent level- Returns:
- this builder (for chaining)
- Since:
- 4.0.0
-
indent
public int indent()
Gets the level of indentation to be used by the resultant loader.- Returns:
- the indent level
- Since:
- 4.0.0
-
lenient
public @NonNull GsonConfigurationLoader.Builder lenient(boolean lenient)
Sets if the resultant loader should parse leniently.- Parameters:
lenient
- whether the parser should parse leniently- Returns:
- this builder (for chaining)
- Since:
- 4.0.0
- See Also:
JsonReader.setLenient(boolean)
-
lenient
public boolean lenient()
Gets if the resultant loader should parse leniently.- Returns:
- whether the parser should parse leniently
- Since:
- 4.0.0
-
build
public @NonNull GsonConfigurationLoader build()
- Specified by:
build
in classorg.spongepowered.configurate.loader.AbstractConfigurationLoader.Builder<GsonConfigurationLoader.Builder,GsonConfigurationLoader>
-
-