DimensionLayer class final
A layer that can visualize dimension features data.
Dimension features are a special kind of annotation feature for showing specific lengths or distances on a map. A dimension may indicate the length of a side of a building or land parcel, or the distance between two features, such as a fire hydrant and the corner of a building. They are described in detail in "Dimension".
Each Dimension feature has specific text and specific locations for its schematic lines and arrows.
Dimension features are not linked to other point, line or polygon features, even if the dimension measurement was created to refer to one or more features.
You can construct a dimension layer using a feature table containing dimension features:
- An online ServiceFeatureTable that has a feature layer service type of ArcGISFeatureLayerInfoServiceType.dimensionLayer
- An offline GeodatabaseFeatureTable returned by the Geodatabase.geodatabaseDimensionTables collection when a GenerateGeodatabaseJob has completed
Dimension layers can be taken offline from a feature service hosted on ArcGIS Enterprise 10.9 or later, using the GeodatabaseSyncTask. Dimension layers are also supported in mobile map packages or mobile geodatabases created in ArcGIS Pro 2.9 or later.
Dimension respects the reference scale defined by the map, so dimension will always be presented to the user at the correct size and position, as defined by the dimension author.
You cannot add, change, or delete a dimension feature. Any attempt produces a "Geodatabase table not editable" (3016) error.
The DimensionLayer.featureTable associated with this DimensionLayer contains a set of attributes (fields, in other words) that define "dimensions". These attributes, automatically added by ArcGIS Pro, are described in "Dimension fields". The author of the dimension layer may have also added additional fields. You can query and use any of these attributes in a definition expression but you cannot change their value.
You do not have access to, and cannot change, the renderer or the styles used for rendering dimensions.
Constructors
- DimensionLayer.withFeatureTable(ArcGISFeatureTable featureTable)
-
Creates a dimension layer from a feature table containing dimension
features.
factory
- DimensionLayer.withItem({required Item item, required int layerId})
-
Creates a new dimension layer object from a feature service portal item.
factory
- DimensionLayer.withUri(Uri uri)
-
Creates a new dimension layer from a feature service URI.
factory
Properties
- attribution → String
-
The attribution text for the layer.
no setterinherited
- canChangeVisibility → bool
-
A flag indicating whether the layer content's visibility can be changed.
no setterinherited
- definitionExpression ↔ String
-
A SQL statement where clause that stipulates a subset of features to be
displayed.
getter/setter pair
- description ↔ String
-
The description for the layer.
getter/setter pairinherited
- featureTable → ArcGISFeatureTable?
-
The feature table associated with this layer.
no setter
- fullExtent → Envelope?
-
The full extent of this layer, which is the extent where all layer data is
contained.
no setterinherited
- hashCode → int
-
The hash code for this object.
no setterinherited
- id ↔ String
-
The unique identifying string for the layer, as specified in a map or
scene.
getter/setter pairinherited
- isIdentifyEnabled → bool
-
True if the layer supports identify, false otherwise.
no setterinherited
- isVisible ↔ bool
-
The layer content's visibility.
getter/setter pairinherited
- item → Item?
-
The item the layer has been created from.
no setterinherited
- layerId → int
-
The layer ID that defines the layer within the feature service portal
item.
no setter
- loadError → ArcGISException?
-
The load error.
no setterinherited
- loadStatus → LoadStatus
-
The load status.
no setterinherited
- maxScale ↔ double
-
The maximum scale for the layer.
getter/setter pairinherited
- minScale ↔ double
-
The minimum scale for the layer.
getter/setter pairinherited
- name ↔ String
-
The layer content's name.
getter/setter pairinherited
-
onLoadStatusChanged
→ Stream<
LoadStatus> -
A stream that reports changes to the
LoadStatus
.no setterinherited -
onSubLayerContentChanged
→ Stream<
List< LayerContent> > -
Callback invoked when the sublayer content of the layer content have
changed.
no setterinherited
-
onVisibilityChanged
→ Stream<
bool> -
Callback invoked when the visibility of the layer changes.
no setterinherited
- opacity ↔ double
-
The opacity for the layer.
getter/setter pairinherited
- referenceScale → double
-
The reference scale for the layer.
no setter
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
- showInLegend ↔ bool
-
A flag indicating whether the layer content participates in the legend.
getter/setter pairinherited
- spatialReference → SpatialReference?
-
The spatial reference of the layer.
no setterinherited
-
subLayerContents
→ List<
LayerContent> -
The sub layer contents of a layer content.
no setterinherited
- uri → Uri?
-
The URI of a feature service to define the layer.
no setter
Methods
-
cancelLoad(
) → void -
Cancels loading metadata for the object.
inherited
-
clearSelection(
) → void - Updates any selected features in the layer back to the un-selected state.
-
clone(
) → Layer -
Clones this instance of the layer and its members.
inherited
-
fetchLegendInfos(
) → Future< List< LegendInfo> > -
Fetches the list of legend info.
inherited
-
getSelectedFeatures(
) → Future< FeatureQueryResult> - Returns a list of the currently selected features.
-
isVisibleAtScale(
double scale) → bool -
Returns the layer content's effective visibility at the specified scale.
inherited
-
load(
) → Future< void> -
Loads the metadata for the object asynchronously.
inherited
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
resetFeaturesVisible(
) → void - Resets the visibility of the layer's features back to the original visibility when loaded from the data source.
-
retryLoad(
) → Future< void> -
Loads or retries loading metadata for the object asynchronously.
inherited
-
selectFeature(
Feature feature) → void - Selects the given feature and adds it to the current list of selected features.
-
selectFeatures(
List< Feature> features) → void - Selects the features in the list and adds them to the current list of selected features.
-
selectFeaturesWithQuery(
{required QueryParameters parameters, required SelectionMode mode}) → Future< FeatureQueryResult> - Selects the features that match the criteria in the QueryParameters object and adds them to the current list of selected features.
-
setFeaturesVisible(
{required List< Feature> features, required bool visible}) → void - Sets the visibility of the given features.
-
setFeatureVisible(
{required Feature feature, required bool visible}) → void - Sets the visibility of the given feature.
-
toString(
) → String -
A string representation of this object.
inherited
-
unselectFeature(
Feature feature) → void - Unselects the given feature and removes it from the current list of selected features.
-
unselectFeatures(
List< Feature> features) → void - Unselects the features in the given list and removes them from the current list of selected features.
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited