Package kr.toxicity.model.api.data.raw
Interface ModelOutliner
- All Known Implementing Classes:
ModelOutliner.Reference,ModelOutliner.Tree
Represents the hierarchical structure (outliner) of a model.
The outliner defines the parent-child relationships between groups and elements (cubes, locators, etc.). It can be either a direct reference to an element (UUID string) or a tree node (Group) containing children.
- Since:
- 1.15.2
-
Nested Class Summary
Nested ClassesModifier and TypeInterfaceDescriptionstatic final recordRepresents a leaf node in the outliner, referencing a specific element by UUID.static final recordRepresents a branch node (Group) in the outliner, containing child nodes. -
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final com.google.gson.JsonDeserializer<ModelOutliner> A JSON deserializer that parses the outliner structure. -
Method Summary
Modifier and TypeMethodDescription@NotNull Stream<ModelOutliner> flatten()Flattens the outliner tree into a stream of all nodes.@NotNull BlueprintElementtoBlueprint(@NotNull ModelLoadContext context) Converts this outliner node into a processedBlueprintElement.@NotNull Stringuuid()Returns the UUID of this outliner node.
-
Field Details
-
PARSER
A JSON deserializer that parses the outliner structure.It distinguishes between leaf nodes (UUID strings) and branch nodes (Groups with children).
- Since:
- 1.15.2
-
-
Method Details
-
toBlueprint
Converts this outliner node into a processedBlueprintElement.- Parameters:
context- the model loading context- Returns:
- the blueprint element
- Since:
- 1.15.2
-
flatten
Flattens the outliner tree into a stream of all nodes.- Returns:
- a stream of all outliner nodes
- Since:
- 1.15.2
-
uuid
Returns the UUID of this outliner node.- Returns:
- the UUID string
- Since:
- 1.15.2
-