Class BaseVectorLayer<S extends AbstractVectorSource>
- All Implemented Interfaces:
- HasBaseLayerOptions,- HasBaseVectorOptions,- Serializable
- Direct Known Subclasses:
- NoOpVectorLayer,- VectorLayer
For more details see: BaseVectorLayer docs
- See Also:
- 
Nested Class SummaryNested classes/interfaces inherited from class io.jmix.mapsflowui.kit.component.model.MapObservableObjectMapObservableObject.ObjectChangeEvent
- 
Field SummaryFieldsFields inherited from class io.jmix.mapsflowui.kit.component.model.MapObservableObjectchildren, dirty, eventBus, listener, metaProperties, removedChildren, syncId
- 
Constructor SummaryConstructors
- 
Method SummaryModifier and TypeMethodDescriptionAdds styles that should be merged with default.protected HasBaseVectorOptionsvoidClears list of styles.voidremoveStyles(Style... styles) Removes provided styles from layer.voidsetBackground(String color) Sets the background color for the layer.voidsetDeclutter(Boolean declutter) Sets whether declutter images and texts.voidsetRenderBuffer(Double renderBuffer) Sets the buffer in pixels around the viewport extent used by the renderer when getting features from the vector source for the rendering or hit-detection.voidsetUpdateWhileAnimating(Boolean updateWhileAnimating) Sets whether feature batches will be recreated during animations.voidsetUpdateWhileInteracting(Boolean updateWhileInteracting) Sets whether feature batches will be recreated during interactions.withBackground(String color) withDeclutter(Boolean declutter) withRenderBuffer(Double renderBuffer) withUpdateWhileAnimating(Boolean updateWhileAnimating) withUpdateWhileInteracting(Boolean updateWhileInteracting) Methods inherited from class io.jmix.mapsflowui.kit.component.model.layer.LayercreateOptions, getClassName, getExtent, getId, getMaxZoom, getMinZoom, getOpacity, getSource, getZIndex, isVisible, setClassName, setExtent, setId, setMaxZoom, setMinZoom, setOpacity, setSource, setVisible, setZIndex, withClassName, withExtent, withId, withMaxZoom, withMinZoom, withOpacity, withSource, withVisible, withZIndexMethods inherited from class io.jmix.mapsflowui.kit.component.model.MapObservableObjectaddChild, addListener, clearRemovedChildren, clearRemovedChildrenInDepth, equals, fireChangeEvent, getChildren, getEventBus, getMetaProperties, getRemovedChildren, getSyncId, getType, hashCode, isDirty, isDirtyInDepth, markAsDirty, markAsDirtyInDepth, removeChild, setMapObjectChangeListener, setMetaProperty, unmarkDirtyInDepthMethods inherited from class java.lang.Objectclone, finalize, getClass, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface io.jmix.mapsflowui.kit.component.model.layer.option.HasBaseLayerOptionsgetClassName, getExtent, getMaxZoom, getMinZoom, getOpacity, getZIndex, isVisible, setClassName, setExtent, setMaxZoom, setMinZoom, setOpacity, setVisible, setZIndex
- 
Field Details- 
styles
 
- 
- 
Constructor Details- 
BaseVectorLayerpublic BaseVectorLayer()
 
- 
- 
Method Details- 
getRenderBuffer- Specified by:
- getRenderBufferin interface- HasBaseVectorOptions
- Returns:
- the render buffer in pixels, nullvalue means that default value is used:100
 
- 
setRenderBufferDescription copied from interface:HasBaseVectorOptionsSets the buffer in pixels around the viewport extent used by the renderer when getting features from the vector source for the rendering or hit-detection. The hit detection only checks features that are within a certain distance of the given position. For large icons, the actual geometry of a feature might be too far away and is not considered. Recommended value: the size of the largest symbol, line width or label.Note, render buffer is set only at creation time and cannot be changed at runtime. For more details see: BaseVectorLayer docs - Specified by:
- setRenderBufferin interface- HasBaseVectorOptions
 
- 
withRenderBuffer- Parameters:
- renderBuffer-
- Returns:
- current instance
 
- 
isDeclutter- Specified by:
- isDeclutterin interface- HasBaseVectorOptions
- Returns:
- whether declutter images and texts, nullvalue means that default value is used:false
 
- 
setDeclutterDescription copied from interface:HasBaseVectorOptionsSets whether declutter images and texts. Decluttering is applied to all image and text styles of all vector layers that have set this totrue. The priority is defined by the z-index of the layer, theStyle.withZIndex(Integer)of the style and the render order of features. Higher z-index means higher priority. Within the same z-index, a feature rendered before another has higher priority.As an optimization decluttered features from layers with the same HasBaseLayerOptions.setClassName(String)are rendered above theFillandStrokestyles of all of those layers regardless of z-index. To opt out of this behavior and place declutterd features with their own layer configure the layer with a className other than 'ol-layer'.The default value is false.Note, declutter is set only at creation time and cannot be changed at runtime. For more details see: BaseVectorLayer docs - Specified by:
- setDeclutterin interface- HasBaseVectorOptions
- Parameters:
- declutter- whether declutter images and texts
 
- 
withDeclutter- Parameters:
- declutter-
- Returns:
- current instance
 
- 
getBackground- Specified by:
- getBackgroundin interface- HasBaseVectorOptions
- Returns:
- background color for the layer or nullif not set
 
- 
setBackgroundDescription copied from interface:HasBaseVectorOptionsSets the background color for the layer. If not specified, no background will be rendered.Note, background color is set only at creation time and cannot be changed at runtime. For more details see: BaseVectorLayer docs - Specified by:
- setBackgroundin interface- HasBaseVectorOptions
- Parameters:
- color- color to set
 
- 
withBackground- Parameters:
- color-
- Returns:
- current instance
 
- 
isUpdateWhileAnimating- Specified by:
- isUpdateWhileAnimatingin interface- HasBaseVectorOptions
- Returns:
- whether feature batches will be recreated during animations, nullvalue means that default value is used:false
 
- 
setUpdateWhileAnimatingDescription copied from interface:HasBaseVectorOptionsSets whether feature batches will be recreated during animations. This means that no vectors will be shown clipped, but the setting will have a performance impact for large amounts of vector data. When set tofalse, batches will be recreated when no animation is active.The default value is false.Note, "updateWhileAnimating" is set only at creation time and cannot be changed at runtime. For more details see: BaseVectorLayer docs - Specified by:
- setUpdateWhileAnimatingin interface- HasBaseVectorOptions
- Parameters:
- updateWhileAnimating- whether feature batches will be recreated during animations
 
- 
withUpdateWhileAnimating- Parameters:
- updateWhileAnimating-
- Returns:
 
- 
getUpdateWhileInteracting- Specified by:
- getUpdateWhileInteractingin interface- HasBaseVectorOptions
- Returns:
- whether feature batches will be recreated during interactions, nullvalue means that default value is used:false
 
- 
setUpdateWhileInteractingDescription copied from interface:HasBaseVectorOptionsSets whether feature batches will be recreated during interactions. The default value isfalse.For instance, if the user moves map by mouse, the features that were not visible will be drawn after the user releases the pressed mouse. To enable always drawing features, set property to true.Note, "updateWhileInteracting" is set only at creation time and cannot be changed at runtime. For more details see: BaseVectorLayer docs - Specified by:
- setUpdateWhileInteractingin interface- HasBaseVectorOptions
- Parameters:
- updateWhileInteracting- whether feature batches will be recreated during interactions
 
- 
withUpdateWhileInteracting- Parameters:
- updateWhileInteracting-
- Returns:
- current instance
 
- 
getStyles- Returns:
- layer's styles or empty list
 
- 
addStylesAdds styles that should be merged with default. Layer's styles are applied for all added features, except features with own style.- Parameters:
- styles- styles to add
- Returns:
- current instance
 
- 
removeStylesRemoves provided styles from layer.- Parameters:
- styles- styles to remove
 
- 
removeAllStylespublic void removeAllStyles()Clears list of styles.
- 
getOptions- Specified by:
- getOptionsin class- Layer<S extends AbstractVectorSource>
 
 
-