LineDataBuilder (API Reference)
Class LineDataBuilder
Builder of LineData instances.
Note: This is a beta release of this feature, so there could be a few bugs and unexpected behavior. Related APIs may change for new releases without a deprecation process.
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionbuild()Builds an instance ofLineDataand resets the builder instance.withAttributes(DataAttributes attributes) Configures the builder with custom attributes for line to be created.withGeometry(GeoPolyline geometry) Configures the builder with geometry for line to be created.
-
Constructor Details
-
LineDataBuilder
public LineDataBuilder()Creates a builder instance.
-
-
Method Details
-
withGeometry
Configures the builder with geometry for line to be created.
- Parameters:
geometry-Geometry of the polyline. Each vertex defines two line segments: one with a previous vertex and one with a next vertex. First and last vertices don't have resp. previous and next vertices and thus belong to single line segments. Consecutive duplicate vertices are ignored. Altitude of polyline vertices is ignored.
- Returns:
The builder.
-
withAttributes
Configures the builder with custom attributes for line to be created.
- Parameters:
attributes-Custom data attributes to be associated with the line.
- Returns:
The builder.
-
build
Builds an instance of
LineDataand resets the builder instance.- Returns:
Instance of
LineDatacreated with the configured parameters.
-