Interface ANSIComponentSerializer.Builder
- All Superinterfaces:
- AbstractBuilder<ANSIComponentSerializer>
- Enclosing interface:
- ANSIComponentSerializer
public static interface ANSIComponentSerializer.Builder
extends AbstractBuilder<ANSIComponentSerializer>
A builder for the ANSI component serializer.
- Since:
- 4.14.0
- 
Method SummaryModifier and TypeMethodDescription@NotNull ANSIComponentSerializerbuild()Builds the serializer.@NotNull ANSIComponentSerializer.BuildercolorLevel(@NotNull net.kyori.ansi.ColorLevel colorLevel) Sets the default color level used when serializing.@NotNull ANSIComponentSerializer.Builderflattener(@NotNull ComponentFlattener componentFlattener) Sets the component flattener instance to use when traversing the component for serialization.
- 
Method Details- 
colorLevel@NotNull @NotNull ANSIComponentSerializer.Builder colorLevel(@NotNull @NotNull net.kyori.ansi.ColorLevel colorLevel) Sets the default color level used when serializing.By default, this serializer will use ColorLevel.compute()to try to detect the color level of the terminal being used.- Parameters:
- colorLevel- the color level
- Returns:
- this builder
- Since:
- 4.14.0
- See Also:
- 
- ColorLevel
 
 
- 
flattener@NotNull @NotNull ANSIComponentSerializer.Builder flattener(@NotNull @NotNull ComponentFlattener componentFlattener) Sets the component flattener instance to use when traversing the component for serialization.By default, this serializer will use ComponentFlattener.basic().- Parameters:
- componentFlattener- the flattener instance.
- Returns:
- this builder
- Since:
- 4.14.0
 
- 
buildBuilds the serializer.- Specified by:
- buildin interface- AbstractBuilder<ANSIComponentSerializer>
- Returns:
- the built serializer
 
 
-