@LcdService(service=ILcdSLDGXYLayerFactory.class, priority=50000) public final class TLcdSLDGXYLayerTreeNodeFactory extends Object implements ILcdSLDGXYLayerFactory
ILcdLayerTreeNode
's) for models with sub-models
(ILcdModelTreeNode
's). It loops over all sub-models and creates a layer for each. To create the sub-layers,
it either uses a provided SLD layer factory, or by default, all layer factories registered with the service loader.
It only accepts ILcdModelTreeNode
's that are empty,
so ones that don't have data in the nodes, only in the leafs. This is by far the most common case. It has a fall back
priority to allow more specialized layer factories to easily overrule this generic implementation.Constructor and Description |
---|
TLcdSLDGXYLayerTreeNodeFactory()
Creates a new layer node factory.
|
TLcdSLDGXYLayerTreeNodeFactory(Supplier<ILcdSLDGXYLayerFactory> aLeafLayerFactorySupplier)
Creates a new layer node factory.
|
Modifier and Type | Method and Description |
---|---|
ILcdGXYLayer |
createGXYLayer(ILcdModel aModel,
List<TLcdSLDFeatureTypeStyle> aSLDFeatureTypeStyles)
Creates an
ILcdGXYLayer for representing
the given ILcdModel on an ILcdGXYView , according to the given TLcdSLDFeatureTypeStyle 's. |
public TLcdSLDGXYLayerTreeNodeFactory()
TLcdServiceLoader
.public TLcdSLDGXYLayerTreeNodeFactory(Supplier<ILcdSLDGXYLayerFactory> aLeafLayerFactorySupplier)
aLeafLayerFactorySupplier
- Supplier of the layer factory used to create the leafs of the layer tree.public ILcdGXYLayer createGXYLayer(ILcdModel aModel, List<TLcdSLDFeatureTypeStyle> aSLDFeatureTypeStyles)
ILcdSLDGXYLayerFactory
ILcdGXYLayer
for representing
the given ILcdModel
on an ILcdGXYView
, according to the given TLcdSLDFeatureTypeStyle
's.createGXYLayer
in interface ILcdSLDGXYLayerFactory
aModel
- the model that needs to be visualized in an ILcdGXYView
aSLDFeatureTypeStyles
- the SLD feature type style(s) defining how the model should be visually represented on the viewnull
if a layer cannot be created (e.g. because this layer
factory doesn't support the given model).