LineDataSourceBuilder (API Reference)
Class LineDataSourceBuilder
Builder of lines data source.
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
ConstructorsConstructorDescriptionLineDataSourceBuilder(MapContext context) Creates a data source builder instance in the given context. -
Method Summary
Modifier and TypeMethodDescriptionbuild()Builds instance of LineDataSource.Configures the builder to use the given name for data source.withPolyline(LineData polyline) Configures the builder to insert the given polyline in the data source.withPolylines(List<LineData> polylines) Configures the builder to insert the given polylines in the data source.
-
Constructor Details
-
LineDataSourceBuilder
Creates a data source builder instance in the given context.
- Parameters:
context-Map context to associate the data source with.
-
-
Method Details
-
withName
Configures the builder to use the given name for data source.
- Parameters:
dataSourceName-Name of the created data source. Must be unique.
- Returns:
This data source builder instance.
-
withPolyline
Configures the builder to insert the given polyline in the data source.
- Parameters:
polyline-Polyline to add.
- Returns:
This data source builder instance.
-
withPolylines
Configures the builder to insert the given polylines in the data source.
- Parameters:
polylines-Polylines to add.
- Returns:
This data source builder instance.
-
build
Builds instance of LineDataSource.
- Returns:
Instance of the data source created with given polylines and attributes.
-