Package com.luciad.format.sqlite.lvdb
Class TLcdLVDBModelEncoder
java.lang.Object
com.luciad.format.sqlite.lvdb.TLcdLVDBModelEncoder
- All Implemented Interfaces:
ILcdModelEncoder,ILcdStatusSource,Serializable
@LcdService(service=ILcdModelEncoder.class,
priority=20000)
public class TLcdLVDBModelEncoder
extends Object
implements ILcdModelEncoder, ILcdStatusSource
A model encoder that converts models containing vector data.
This format is intended for use only with existing Luciad applications and should not be used otherwise.
If you are looking for an SQLite-based exchange format, we advise to use OGC GeoPackage instead.
- Metadata in these models will be
encoded based on the model descriptor if it's an instance of
ILcdDataModelDescriptororILcdFeaturedDescriptor.
- Since:
- 2013.1
- See Also:
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidaddStatusListener(ILcdStatusListener aStatusListener) Registers the given listener so it will receive status events from this source.booleanReturns whether this encoder can export the specified model to the specified destination.booleanReturns whether this model encoder can save the specified model to the location it originally came from.voidExports the specified model to the specified destination.Returns the bounds of the area to encode.Returns the reference the current area to encode is defined in.Returns a short, displayable name for the format thisILcdModelEncoderencodes to.voidremoveStatusListener(ILcdStatusListener aStatusListener) Removes the specified listener so it is no longer notified.voidSaves the model to the location where it originally came from.voidsetAreaOfInterest(ILcdBounds aAreaOfInterest, ILcdGeoReference aAreaOfInterestReference) Sets the bounds to encode.
-
Constructor Details
-
TLcdLVDBModelEncoder
public TLcdLVDBModelEncoder()Creates a newTLcdLVDBModelEncoder.
-
-
Method Details
-
getDisplayName
Description copied from interface:ILcdModelEncoderReturns a short, displayable name for the format thisILcdModelEncoderencodes to.- Specified by:
getDisplayNamein interfaceILcdModelEncoder- Returns:
- the displayable name of this
ILcdModelEncoder.
-
canSave
Description copied from interface:ILcdModelEncoderReturns whether this model encoder can save the specified model to the location it originally came from. Often this will only be a simple test, for example checking the type of the model's model descriptor.- Specified by:
canSavein interfaceILcdModelEncoder- Parameters:
aModel- the model to be verified.- Returns:
trueif this encoder can save the model in the location where it originally came from,falseotherwise.- See Also:
-
save
Description copied from interface:ILcdModelEncoderSaves the model to the location where it originally came from.- Specified by:
savein interfaceILcdModelEncoder- Parameters:
aModel- the model to be saved.- Throws:
IllegalArgumentException- if the model cannot be saved by this encoder (!canSave(aModel)).IOException- if an I/O error occurs during encoding.
-
canExport
Description copied from interface:ILcdModelEncoderReturns whether this encoder can export the specified model to the specified destination. This method will typically check whether the contents of the specified model are compatible with the format this encoder is written for.- Specified by:
canExportin interfaceILcdModelEncoder- Parameters:
aModel- the model to be verified.aDestination- the location where the model should be exported to.- Returns:
trueif this encoder can export the specified model to the specified location,falseotherwise.- See Also:
-
export
public void export(ILcdModel aModel, String aDestination) throws IllegalArgumentException, IOException Description copied from interface:ILcdModelEncoderExports the specified model to the specified destination.- Specified by:
exportin interfaceILcdModelEncoder- Parameters:
aModel- the model to be exported.aDestination- the location where the model should be saved. Typically, this is a name for the output file, but it can also point to a file containing the required properties to create a set of data files.- Throws:
IllegalArgumentException- if the model cannot be saved by this encoder (!canExport(aModel, aDestinationName)).IOException- if an I/O error occurs during encoding.
-
getAreaOfInterest
Returns the bounds of the area to encode.- Returns:
- the current area to encode.
- See Also:
-
getAreaOfInterestReference
Returns the reference the current area to encode is defined in.- Returns:
- the reference of the area to encode.
- See Also:
-
setAreaOfInterest
public void setAreaOfInterest(ILcdBounds aAreaOfInterest, ILcdGeoReference aAreaOfInterestReference) Sets the bounds to encode. Only the vector data overlapping with this area will be encoded.- Parameters:
aAreaOfInterest- the new bounds to encode, ornullif no bounds should be used.aAreaOfInterestReference- the reference the bounds are defined in.
-
addStatusListener
Description copied from interface:ILcdStatusSourceRegisters the given listener so it will receive status events from this source.
In case you need to register a listener which keeps a reference to an object with a shorter life-time than this status source, you can use a
ALcdWeakStatusListenerinstance as status listener.- Specified by:
addStatusListenerin interfaceILcdStatusSource- Parameters:
aStatusListener- The listener to be notified when the status has changed.
-
removeStatusListener
Description copied from interface:ILcdStatusSourceRemoves the specified listener so it is no longer notified.- Specified by:
removeStatusListenerin interfaceILcdStatusSource- Parameters:
aStatusListener- The listener to remove.
-