Class TLcyDrawingModelDescriptor
java.lang.Object
com.luciad.model.TLcdModelDescriptor
com.luciad.model.TLcdFeaturedModelDescriptor
com.luciad.lucy.addons.drawing.model.TLcyDrawingModelDescriptor
- All Implemented Interfaces:
ILcdModelDescriptor
,ILcdFeaturedDescriptor
,ILcdFeaturedDescriptorProvider
,Serializable
- Direct Known Subclasses:
TLcyDrawingDataModelDescriptor
The ILcdModelDescriptor
used by the models created by the TLcyDrawingFormat
when
specified in the configuration file of the drawing add-on.
The default ILcdModelDescriptor
for drawing models is the TLcyDrawingDataModelDescriptor
.
- Since:
- 8.2
- See Also:
-
Field Summary
Fields inherited from class com.luciad.model.TLcdFeaturedModelDescriptor
fFeatureClasses
-
Constructor Summary
ConstructorDescriptionTLcyDrawingModelDescriptor
(String aSourceName, String aDisplayName) Constructs a newTLcyDrawingModelDescriptor
with the given parametersTLcyDrawingModelDescriptor
(String aSourceName, String aDisplayName, TLcyDrawingStyleRepository aDrawingModelStyle) Constructs a newTLcyDrawingModelDescriptor
with the given parameters -
Method Summary
Modifier and TypeMethodDescriptionvoid
addFeature
(String aFeatureName, Class aFeatureType) Add an extra feature to the modelReturns theTLcyDrawingStyleRepository
, associated with this model, and which contains all the permanent available stylesgetFeatureClass
(int i) Returns theClass
of the feature at the given index.int
Returns the number of features.int
Returns the index of the given feature name if it exists, -1 otherwise.getFeatureName
(int i) Returns the name of the feature at the given index.void
removeFeature
(int index) Removes the feature at indexindex
void
setFeature
(int index, String aFeatureName, Class aFeatureType) Edit an existing featureMethods inherited from class com.luciad.model.TLcdFeaturedModelDescriptor
getFeaturedDescriptor
Methods inherited from class com.luciad.model.TLcdModelDescriptor
getDisplayName, getSourceName, getTypeName, setDisplayName, setSourceName, setTypeName, sourceNameToDisplayName
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface com.luciad.util.ILcdFeaturedDescriptor
getFeatureUnitOfMeasure
Methods inherited from interface com.luciad.model.ILcdModelDescriptor
getDisplayName, getSourceName, getTypeName
-
Constructor Details
-
TLcyDrawingModelDescriptor
Constructs a newTLcyDrawingModelDescriptor
with the given parameters- Parameters:
aSourceName
- the source nameaDisplayName
- the display name
-
TLcyDrawingModelDescriptor
public TLcyDrawingModelDescriptor(String aSourceName, String aDisplayName, TLcyDrawingStyleRepository aDrawingModelStyle) Constructs a newTLcyDrawingModelDescriptor
with the given parameters- Parameters:
aSourceName
- the source nameaDisplayName
- the display nameaDrawingModelStyle
- Repository containing SLD styles which can be used by the domain objects
-
-
Method Details
-
getFeatureCount
public int getFeatureCount()Description copied from interface:ILcdFeaturedDescriptor
Returns the number of features.- Specified by:
getFeatureCount
in interfaceILcdFeaturedDescriptor
- Overrides:
getFeatureCount
in classTLcdFeaturedModelDescriptor
- Returns:
- the number of features.
-
getFeatureName
Description copied from interface:ILcdFeaturedDescriptor
Returns the name of the feature at the given index.- Specified by:
getFeatureName
in interfaceILcdFeaturedDescriptor
- Overrides:
getFeatureName
in classTLcdFeaturedModelDescriptor
- Parameters:
i
- a valid feature index.- Returns:
- the name of the feature at the given index.
-
getFeatureIndex
Description copied from interface:ILcdFeaturedDescriptor
Returns the index of the given feature name if it exists, -1 otherwise.- Specified by:
getFeatureIndex
in interfaceILcdFeaturedDescriptor
- Overrides:
getFeatureIndex
in classTLcdFeaturedModelDescriptor
- Parameters:
s
- a feature name.- Returns:
- the index of the given feature name if it exists, -1 otherwise.
-
getFeatureClass
Description copied from interface:ILcdFeaturedDescriptor
Returns theClass
of the feature at the given index.- Specified by:
getFeatureClass
in interfaceILcdFeaturedDescriptor
- Overrides:
getFeatureClass
in classTLcdFeaturedModelDescriptor
- Parameters:
i
- a valid feature index.- Returns:
- the
Class
of the feature at the given index.
-
addFeature
Add an extra feature to the model- Parameters:
aFeatureName
- the name of the new featureaFeatureType
- the type of the new feature
-
setFeature
Edit an existing feature- Parameters:
index
- the index of the feature which will be editedaFeatureName
- the new name for the feature at indexindex
aFeatureType
- the new type for the feature at indexindex
- Throws:
ArrayIndexOutOfBoundsException
- if the index does not exist.
-
removeFeature
public void removeFeature(int index) Removes the feature at indexindex
- Parameters:
index
- the index of the feature which will be removed- Throws:
ArrayIndexOutOfBoundsException
- if the index does not exist.
-
getDrawingStyleRepository
Returns theTLcyDrawingStyleRepository
, associated with this model, and which contains all the permanent available styles- Returns:
- the
TLcyDrawingStyleRepository
, associated with this model
-