Skip To Content ArcGIS for Developers Sign In Dashboard

ClassBreaksRenderer QML Type

A renderer that displays various symbols based on ranges of attribute values. More...

Import Statement: import Esri.ArcGISRuntime 100.6
Since: Esri.ArcGISRuntime 100.0
Inherits:

Renderer

Properties

Signals

Detailed Description

A class breaks renderer symbolizes each graphic or feature based on the value of some numeric attribute. Graphics and features with similar values for the attribute get the same symbol. The "breaks" define the values at which the symbology changes.

For example, suppose you have a "buildings" layer with an attribute that defines the building's age. You want to symbolize buildings constructed since the year 2000 in green, buildings constructed between 1980 and 2000 in yellow, and buildings built before 1980 with red. This would be a good scenario for class breaks renderer.

Any value that is greater than or equal to the minimum and less than the maximum will be included in the break.

This QML type supports the following default properties. A default property may be declared inside another declared object without being assigned explicitly to a property.

Example:

Apply a ClassBreaksRenderer to a point feature layer repesenting cities of different population sizes:

FeatureLayer {
    id: classRendererLayer

    ServiceFeatureTable {
        url: sampleServerWildFireUrl
    }

    ClassBreaksRenderer {
        fieldName: "Population"

        ClassBreak {
            label: "Small cities"
            description: "Cities with less than 50,000 people"
            minValue: 0
            maxValue: 50000

            SimpleMarkerSymbol {style: Enums.SimpleMarkerSymbolStyleCircle; color: "gray"; size: 5}
        }

        ClassBreak {
            label: "Moderate cities"
            description: "Cities with between 50,000 and 100,000 people"
            minValue: 50001
            maxValue: 100000

            SimpleMarkerSymbol {style: Enums.SimpleMarkerSymbolStyleCircle; color: "green"; size: 10}
        }

        ClassBreak {
            label: "Large cities"
            description: "Cities with between 100,000 and 500,000 people"
            minValue: 100001
            maxValue: 500000

            SimpleMarkerSymbol {style: Enums.SimpleMarkerSymbolStyleCircle; color: "blue"; size: 15}
        }

        ClassBreak {
            label: "Very large cities"
            description: "Cities with between 50,000 and 100,000 people"
            minValue: 500001
            maxValue: 10000000

            SimpleMarkerSymbol {style: Enums.SimpleMarkerSymbolStyleCircle; color: "red"; size: 20}
        }
    }
}

See also JsonSerializable and ClassBreak.

Property Documentation

backgroundFillSymbol : Symbol

The renderer's background fill symbol.

The symbol must be of type SimpleFillSymbol.

By default this symbol will be null. This symbol will only be applied if all of the following conditions apply:

  • The geometry being rendered is of type Polygon.
  • The polygon is symbolised using a ClassBreak with a point symbol at its centroid.

This allows you to symbolise a polygon with a point for the class break but still show its full geometry. For example, a background fill symbol could be added to a ClassBreaksRenderer which shows population polygons with graduated circle symbols to indicate the number of residents. By setting the background symbol, you can show the population quantity as a point and still display the outline of the underlying polygon.

This QML property was introduced in Esri.ArcGISRuntime 100.2.


[default] classBreaks : ClassBreakListModel

Returns a collection of class breaks for the renderer as a ClassBreakListModel (read-only).

The ClassBreakListModel will contain a list model of all the class breaks defined in the renderer.

See also ClassBreakListModel.


classificationMethod : Enums.RendererClassificationMethod

The classification method that was used to generate class breaks.

This QML property was introduced in Esri.ArcGISRuntime 100.2.

See also Enums.RendererClassificationMethod.


defaultLabel : string

The default label.

The default label is used if the graphic or feature's attribute value does not fall into any of the class breaks.


[default] defaultSymbol : Symbol

The default symbol.

The default symbol is used if the graphic or feature's attribute value does not fall into any of the class breaks.


fieldName : string

The attribute field used by the renderer to match values.


minValue : string

The minimum value for this class breaks renderer.


normalizationField : string

The normalizationField for this class breaks renderer.

The normalizationField property is applicable when the normalizationType is by field, as opposed to percent of total or log. The data will be normalized by the value contained in the specified field.

See also Enums.RendererNormalizationType.


normalizationTotal : string

The normalizationTotal for this class breaks renderer.

The normalizationTotal property is applicable when the normalizationType is percent of total, as opposed to by field or log. Use normalizationTotal to obtain the total value.

See also Enums.RendererNormalizationType.


normalizationType : Enums.RendererNormalizationType

The normalizationType for this class breaks renderer.

Set the normalizationType to normalize the data instead of using the raw attribute value.

For example, consider a "cities" layer that contained a total crimes attribute. If you did not normalize the data, the map would symbolize the cities with the highest amount of crimes. However, this could be misleading, as the cities with a higher population would likely have more crimes, simply due to the having more people. You could instead normalize the data by a field called population, so you could visualize the amount of crimes per person.

The normalizationType is used to determine how the data is normalized. If this property is missing, it means no normalization was applied. When normalization type is by field, use the normalizationField property to determine or set the field used to normalize the data. When normalization type is percent of total, use normalizationTotal to determine or set the total value.

See also Enums.RendererNormalizationType.


Signal Documentation

backgroundFillSymbolChanged()

Emitted when the backgroundFillSymbol property changes.

This QML signal was introduced in Esri.ArcGISRuntime 100.2.


classBreaksChanged()

Emitted when the classBreaks property changes.


classificationMethodChanged()

Emitted when the classificationMethod property changes.

This QML signal was introduced in Esri.ArcGISRuntime 100.2.


defaultLabelChanged()

Emitted when the defaultLabel property changes.


defaultSymbolChanged()

Emitted when the defaultSymbol property changes.


fieldNameChanged()

Emitted when the fieldName property changes.


minValueChanged()

Emitted when the minValue property changes.


normalizationFieldChanged()

Emitted when the normalizationField property changes.


normalizationTotalChanged()

Emitted when the normalizationTotal property changes.


normalizationTypeChanged()

Emitted when the normalizationType property changes.



Feedback on this topic?