Package com.luciad.util.height
Class TLcdImageModelHeightProviderFactory
java.lang.Object
com.luciad.util.height.ALcdModelHeightProviderFactory
com.luciad.util.height.ALcdRasterModelHeightProviderFactory
com.luciad.util.height.TLcdImageModelHeightProviderFactory
- All Implemented Interfaces:
ILcdModelHeightProviderFactory
This class provides a method to create an
ILcdHeightProvider
when an
ILcdModel
is given that contains elements of the type
ALcdBasicImage
, ALcdImageMosaic
or
ALcdMultilevelImageMosaic
.
When the model contains elements of type ILcdRaster
or
ILcdMultilevelRaster
, the factory will fall back to the legacy implementation in
TLcdRasterModelHeightProviderFactory
The height providers created by this factory are thread-safe. However when you need to retrieve the height at many
locations its usually more efficient to create a new height provider. This avoids cache conflicts between different
threads need different image data (e.g. tiles) to retrieve their heights.- Since:
- 2014.0
-
Field Summary
Modifier and TypeFieldDescriptionstatic final String
Key used to pass a user-defined imaging engine to theTLcdImageHeightProviders
created by this factory.Fields inherited from class com.luciad.util.height.ALcdRasterModelHeightProviderFactory
KEY_INTERPOLATE_DATA, KEY_MAX_VALID_HEIGHT, KEY_MIN_VALID_HEIGHT, KEY_PIXEL_DENSITY
Fields inherited from interface com.luciad.util.height.ILcdModelHeightProviderFactory
KEY_GEO_REFERENCE
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionprotected boolean
canCreateHeightProvider
(ILcdModel aModel) Check if a height provider can be created from the givenILcdModel
.protected ILcdHeightProvider
createModelElementHeightProvider
(Object aElement, Map<String, Object> aRequiredPropertiesSFCT, Map<String, Object> aOptionalProperties) Creates anILcdHeightProvider
for the given model element.Methods inherited from class com.luciad.util.height.ALcdRasterModelHeightProviderFactory
transformProperties
Methods inherited from class com.luciad.util.height.ALcdModelHeightProviderFactory
createHeightProvider
-
Field Details
-
KEY_IMAGING_ENGINE
Key used to pass a user-defined imaging engine to theTLcdImageHeightProviders
created by this factory. If defined, the property should be aALcdImagingEngine
. If not defined, a default imaging engine will be created for every height provider factory.- See Also:
-
-
Constructor Details
-
TLcdImageModelHeightProviderFactory
public TLcdImageModelHeightProviderFactory()
-
-
Method Details
-
createModelElementHeightProvider
protected ILcdHeightProvider createModelElementHeightProvider(Object aElement, Map<String, Object> aRequiredPropertiesSFCT, Map<String, throws TLcdMissingPropertyException, TLcdUnsupportedPropertyExceptionObject> aOptionalProperties) Description copied from class:ALcdModelHeightProviderFactory
Creates anILcdHeightProvider
for the given model element.- Specified by:
createModelElementHeightProvider
in classALcdRasterModelHeightProviderFactory
- Parameters:
aElement
- a model element.aRequiredPropertiesSFCT
- the required properties.aOptionalProperties
- the optional properties.- Returns:
- an
ILcdHeightProvider
for the given model element ornull
if noILcdHeightProvider
can be created. - Throws:
TLcdMissingPropertyException
- when a property is missing that is necessary to create theILcdHeightProvider
.TLcdUnsupportedPropertyException
- when a required property was never used while creating theILcdHeightProvider
.
-
canCreateHeightProvider
Description copied from class:ALcdRasterModelHeightProviderFactory
Check if a height provider can be created from the givenILcdModel
. The default implementation only returnstrue
if the model contains aTLcdRasterModelDescriptor
or aTLcdMultilevelRasterModelDescriptor
, andfalse
otherwise.- Overrides:
canCreateHeightProvider
in classALcdRasterModelHeightProviderFactory
- Parameters:
aModel
- the given model.- Returns:
true
if a height provider can be created from the given model andfalse
otherwise.
-