Class ALcdASTERIXModelDescriptor
- All Implemented Interfaces:
ILcdDataModelDescriptor,ILcdDataSourceModelDescriptor<TLcdASTERIXDataSource>,ILcdModelDescriptor,ILcdFeaturedDescriptor,ILcdFeaturedDescriptorProvider,Serializable
- Direct Known Subclasses:
TLcdASTERIXPlotModelDescriptor,TLcdASTERIXRadarServiceMessageModelDescriptor,TLcdASTERIXRadarVideoModelDescriptor,TLcdASTERIXTrackModelDescriptor,TLcdASTERIXTrajectoryModelDescriptor,TLcdASTERIXWeatherModelDescriptor
ILcdModelDescriptors that are used to
represent data of some type. Note that the decoders use a
TLcdModelList, and that every sub model of that model list
corresponds to the data of one user application profile. Such a sub model has a model descriptor that is an
extension of this abstract model descriptor.
This model descriptor is a ILcdDataModelDescriptor. As such, it can
be used to retrieve information on the TLcdDataModel used to model the
data in the domain objects. All ASTERIX domain object implement the ILcdDataObject
interface to model attributes such as "Ground speed", "Type", "Received Power",... The values for those properties
are stored in the domain objects, using the ILcdDataObject interface.
To obtain all possible data types of the model element of this model, use the
getModelElementTypes() method. The getModelTypes() can be
used to obtain all data types in the entire data model.
For reasons of backwards compatibility, this model descriptor is also a
ILcdFeaturedDescriptor. Next to ILcdDataObject, ASTERIX
domain objects also implement the ILcdFeatured interface to model
their additional attributes. Additional meta-information about
those features (such as their descriptive name or feature class) can be retrieved using the
methods of the ILcdFeaturedDescriptor interface that is
implemented by this model descriptor. Certain feature values (retrieved
using ILcdFeatured.getFeature(int)) of an ASTERIX domain object
(such as TLcdASTERIXTrack) can again return an
ILcdFeatured object. That object also needs an
ILcdFeaturedDescriptor to be able to specify all meta data. That
ILcdFeaturedDescriptor can be retrieved from this model
descriptor through its ILcdFeaturedDescriptorProvider interface.
Simply invoke getFeaturedDescriptor(com.luciad.util.ILcdFeatured)
for that featured object to obtain the associated
ILcdFeaturedDescriptor.- See Also:
-
Constructor Summary
ConstructorsConstructorDescriptionALcdASTERIXModelDescriptor(TLcdASTERIXDataSource aDataSource, String aTypeName, String aDisplayName, ALcdASTERIXCategory aCategory, ALcdASTERIXUserApplicationProfile aUAP, ALcdASTERIXTransformationProvider aTransformationProvider, ALcdASTERIXScalingFactorProvider aScalingFactorProvider, TLcdDataType aDataType) Constructs a newALcdASTERIXModelDescriptorthat supportsILcdDataModelDescriptor.ALcdASTERIXModelDescriptor(TLcdASTERIXDataSource aDataSource, String aTypeName, String aDisplayName, String[] aFeatureNames, Class[] aFeatureClasses, ALcdASTERIXCategory aCategory, ALcdASTERIXUserApplicationProfile aUAP, ALcdASTERIXTransformationProvider aTransformationProvider, ALcdASTERIXScalingFactorProvider aScalingFactorProvider) Deprecated.ALcdASTERIXModelDescriptor(String aSourceName, String aTypeName, String aDisplayName, ALcdASTERIXCategory aCategory, ALcdASTERIXUserApplicationProfile aUAP, ALcdASTERIXTransformationProvider aTransformationProvider, ALcdASTERIXScalingFactorProvider aScalingFactorProvider, TLcdDataType aDataType) Constructs a newALcdASTERIXModelDescriptorthat supportsILcdDataModelDescriptor.ALcdASTERIXModelDescriptor(String aSourceName, String aTypeName, String aDisplayName, String[] aFeatureNames, Class[] aFeatureClasses, ALcdASTERIXCategory aCategory, ALcdASTERIXUserApplicationProfile aUAP, ALcdASTERIXTransformationProvider aTransformationProvider, ALcdASTERIXScalingFactorProvider aScalingFactorProvider) -
Method Summary
Modifier and TypeMethodDescriptionReturns the ASTERIX category that corresponds with the data in the model.Returns the data model that describes the elements of the model.Returns the data source containing the source names that were decoded.Returns a displayable name for the data source, suitable for usage in user interfaces.getFeatureClass(int aIndex) Returns theClassof the feature at the given index.intReturns the number of features.getFeaturedDescriptor(ILcdFeatured aFeatured) Gets aILcdFeaturedDescriptorthat describes theILcdFeaturedpassed.intgetFeatureIndex(String aFeatureName) Returns the index of the given feature name if it exists, -1 otherwise.getFeatureName(int aIndex) Returns the name of the feature at the given index.Returns a set containing all the data types of which instances can be elements in the model associated with this descriptor.Returns a set containing all the types of which instances can be used (including both top-level elements and child objects) in the model associated with this descriptor.Returns theALcdASTERIXScalingFactorProviderthat corresponds with the data in the model.Returns the full name that uniquely identifies the data source.Returns theALcdASTERIXTransformationProviderthat corresponds with the data in the model.Returns the type/format name of the data source.getUAP()Returns the ASTERIX UAP that corresponds with the data in the model.voidsetDataSource(TLcdASTERIXDataSource aDataSource) Updates the data source of this model descriptor.voidsetDisplayName(String aDisplayName) Sets a new display name for this model descriptor.voidsetSourceName(String aSourceName) Sets a new source name for this model descriptor.Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface com.luciad.util.ILcdFeaturedDescriptor
getFeatureUnitOfMeasure
-
Constructor Details
-
ALcdASTERIXModelDescriptor
@Deprecated public ALcdASTERIXModelDescriptor(String aSourceName, String aTypeName, String aDisplayName, String[] aFeatureNames, Class[] aFeatureClasses, ALcdASTERIXCategory aCategory, ALcdASTERIXUserApplicationProfile aUAP, ALcdASTERIXTransformationProvider aTransformationProvider, ALcdASTERIXScalingFactorProvider aScalingFactorProvider) Constructs a newALcdASTERIXModelDescriptor.- Parameters:
aSourceName- The name of the source.aTypeName- The type of data.aDisplayName- The display name for the model.aFeatureNames- The features names.aFeatureClasses- The feature classes.aCategory- The ASTERIX category that corresponds with the data.aUAP- The User Application Profile (UAP) that corresponds with the data.aTransformationProvider- The transformation provider used for this data source.aScalingFactorProvider- The scaling factor provider used for this data source.
-
ALcdASTERIXModelDescriptor
@Deprecated public ALcdASTERIXModelDescriptor(TLcdASTERIXDataSource aDataSource, String aTypeName, String aDisplayName, String[] aFeatureNames, Class[] aFeatureClasses, ALcdASTERIXCategory aCategory, ALcdASTERIXUserApplicationProfile aUAP, ALcdASTERIXTransformationProvider aTransformationProvider, ALcdASTERIXScalingFactorProvider aScalingFactorProvider) Constructs a newALcdASTERIXModelDescriptor.- Parameters:
aDataSource- The data source containing the source names that were decoded.aTypeName- The type of data.aDisplayName- The display name for the model.aFeatureNames- The features names.aFeatureClasses- The feature classes.aCategory- The ASTERIX category that corresponds with the data.aUAP- The User Application Profile (UAP) that corresponds with the data.aTransformationProvider- The transformation provider used for this data source.aScalingFactorProvider- The scaling factor provider used for this data source.
-
ALcdASTERIXModelDescriptor
public ALcdASTERIXModelDescriptor(String aSourceName, String aTypeName, String aDisplayName, ALcdASTERIXCategory aCategory, ALcdASTERIXUserApplicationProfile aUAP, ALcdASTERIXTransformationProvider aTransformationProvider, ALcdASTERIXScalingFactorProvider aScalingFactorProvider, TLcdDataType aDataType) Constructs a newALcdASTERIXModelDescriptorthat supportsILcdDataModelDescriptor.- Parameters:
aSourceName- The name of the source.aTypeName- The type of data.aDisplayName- The display name for the model.aCategory- The ASTERIX category that corresponds with the data.aUAP- The User Application Profile (UAP) that corresponds with the data.aTransformationProvider- The transformation provider used for this data source.aScalingFactorProvider- The scaling factor provider used for this data source.aDataType- The data type used by all elements of this model.
-
ALcdASTERIXModelDescriptor
public ALcdASTERIXModelDescriptor(TLcdASTERIXDataSource aDataSource, String aTypeName, String aDisplayName, ALcdASTERIXCategory aCategory, ALcdASTERIXUserApplicationProfile aUAP, ALcdASTERIXTransformationProvider aTransformationProvider, ALcdASTERIXScalingFactorProvider aScalingFactorProvider, TLcdDataType aDataType) Constructs a newALcdASTERIXModelDescriptorthat supportsILcdDataModelDescriptor.- Parameters:
aDataSource- The data source containing the source names that were decoded.aTypeName- The type of data.aDisplayName- The display name for the model.aCategory- The ASTERIX category that corresponds with the data.aUAP- The User Application Profile (UAP) that corresponds with the data.aTransformationProvider- The transformation provider used for this data source.aScalingFactorProvider- The scaling factor provider used for this data source.aDataType- The data type used by all elements of this model.
-
-
Method Details
-
getDataSource
Returns the data source containing the source names that were decoded.- Specified by:
getDataSourcein interfaceILcdDataSourceModelDescriptor<TLcdASTERIXDataSource>- Returns:
- An
TLcdASTERIXDataSourceobject, ornullif the source is unspecified. - See Also:
-
setDataSource
Updates the data source of this model descriptor. Changing the data source will also change the source name of this descriptor:- if the data source is
null, the source name will also be set tonull. - if the data source contains a single source name, that source name will also be returned when calling getSourceName
- if the data source contains multiple source names, the source name of this model descriptor will be set
to
null.
- Parameters:
aDataSource- The new data source for this descriptor. This may benull.
- if the data source is
-
getCategory
Returns the ASTERIX category that corresponds with the data in the model.- Returns:
- the ASTERIX category that corresponds with the data in the model.
-
getUAP
Returns the ASTERIX UAP that corresponds with the data in the model.- Returns:
- the ASTERIX UAP that corresponds with the data in the model.
-
getTransformationProvider
Returns theALcdASTERIXTransformationProviderthat corresponds with the data in the model.- Returns:
- The
ALcdASTERIXTransformationProviderthat corresponds with the data in the model.
-
getScalingFactorProvider
Returns theALcdASTERIXScalingFactorProviderthat corresponds with the data in the model.- Returns:
- The
ALcdASTERIXScalingFactorProviderthat corresponds with the data in the model.
-
getFeaturedDescriptor
Gets aILcdFeaturedDescriptorthat describes theILcdFeaturedpassed. Please refer to the class comment for additional information.- Specified by:
getFeaturedDescriptorin interfaceILcdFeaturedDescriptorProvider- Parameters:
aFeatured- a featured object to retrieve a featured descriptor for.- Returns:
- a
ILcdFeaturedDescriptorthat describes theILcdFeaturedpassed.
-
getTypeName
Description copied from interface:ILcdModelDescriptorReturns the type/format name of the data source. The data format String is an easy means to identify a format. It is not guaranteed to be unique, so additional checks may be necessary. This can be mif or shape, for instance.- Specified by:
getTypeNamein interfaceILcdModelDescriptor- Returns:
- the type name of the data source.
-
getDisplayName
Description copied from interface:ILcdModelDescriptorReturns a displayable name for the data source, suitable for usage in user interfaces. This is typically a shortened version of the source name, for example the file name without directory or extension.- Specified by:
getDisplayNamein interfaceILcdModelDescriptor- Returns:
- a displayable name for the data source.
-
getSourceName
Description copied from interface:ILcdModelDescriptorReturns the full name that uniquely identifies the data source. This can be the full file name for a file source, or the table name for a database source, for instance.- Specified by:
getSourceNamein interfaceILcdModelDescriptor- Returns:
- the full name of the data source.
-
setDisplayName
Sets a new display name for this model descriptor.- Parameters:
aDisplayName- the new display name
-
setSourceName
Sets a new source name for this model descriptor. The data source of this model descriptor will also be updated to reflect the source name.- Parameters:
aSourceName- the new source name. May benullto indicate that the source is unknown.
-
getFeatureCount
public int getFeatureCount()Returns the number of features. Please refer to the class comment for additional information.- Specified by:
getFeatureCountin interfaceILcdFeaturedDescriptor- Returns:
- the number of features.
-
getFeatureName
Returns the name of the feature at the given index. Please refer to the class comment for additional information.- Specified by:
getFeatureNamein interfaceILcdFeaturedDescriptor- Parameters:
aIndex- a valid feature index.- Returns:
- the name of the feature at the given index.
-
getFeatureIndex
Returns the index of the given feature name if it exists, -1 otherwise. Please refer to the class comment for additional information.- Specified by:
getFeatureIndexin interfaceILcdFeaturedDescriptor- Parameters:
aFeatureName- a feature name.- Returns:
- the index of the given feature name if it exists, -1 otherwise.
-
getFeatureClass
Returns theClassof the feature at the given index. Please refer to the class comment for additional information.- Specified by:
getFeatureClassin interfaceILcdFeaturedDescriptor- Parameters:
aIndex- a valid feature index.- Returns:
- the
Classof the feature at the given index.
-
getDataModel
Description copied from interface:ILcdDataModelDescriptorReturns the data model that describes the elements of the model. Note that not necessarily all data in the model will be of a type of this data model. Very likely, types from the dependencies of the returned data model are used as well.
In case the model accepts objects from multiple data models, an anonymous data model that depends on all these data models should be returned (see
TLcdDataModelBuilder.createAnonymousDataModel(java.util.Collection)).- Specified by:
getDataModelin interfaceILcdDataModelDescriptor- Returns:
- the data model that describes the elements of the model
-
getModelElementTypes
Description copied from interface:ILcdDataModelDescriptorReturns a set containing all the data types of which instances can be elements in the model associated with this descriptor. Implementations are free to limit the result to only include the types of which there are actually elements in the model; but they are not required to do so.
Implementations should return
nullin case they don't know which element types are present in the model.For each element of the model associated with this model descriptor, the following holds true :
getModelElementTypes().contains( element.getDataType() ).- Specified by:
getModelElementTypesin interfaceILcdDataModelDescriptor- Returns:
- a set containing all the data types of which instances can be elements in the model associated with this descriptor
-
getModelTypes
Description copied from interface:ILcdDataModelDescriptorReturns a set containing all the types of which instances can be used (including both top-level elements and child objects) in the model associated with this descriptor. Implementations are free to limit the result to only include the types of which there are actually instances in the model; but they are not required to do so.
A simple and correct implementation would be to return
getDataModel().getTypes(). Implementations are encouraged to return a subset of this set if they can do so without spending an unreasonable amount of resources.Implementations should return
nullin case they don't know which types are present in the model.- Specified by:
getModelTypesin interfaceILcdDataModelDescriptor- Returns:
- a set containing all the data types of which instances can be used in the model associated with this descriptor
-
ALcdASTERIXModelDescriptor(String, String, String, ALcdASTERIXCategory, ALcdASTERIXUserApplicationProfile, ALcdASTERIXTransformationProvider, ALcdASTERIXScalingFactorProvider, com.luciad.datamodel.TLcdDataType))