ArcGIS Runtime SDK for iOS: AGSUniqueValue Class Reference
ArcGIS Runtime SDK for iOS  100.15
AGSUniqueValue Class Reference

Description

Each unique value that is symbolized differently by a unique value renderer.

Instances of this class represent a unique value of matching attributes that must be symbolized by a unique value renderer.

Since
100
Inheritance diagram for AGSUniqueValue:
AGSObject <AGSJSONSerializable>

Instance Methods

(instancetype) - initWithDescription:label:symbol:values:
 
(instancetype) - initWithDescription:label:symbol:values:alternateSymbols:
 
(BOOL) - isEqualToUniqueValue:
 
(nullable id) - toJSON:
 

Class Methods

(nullable id< AGSJSONSerializable >) + fromJSON:error:
 
(instancetype) + uniqueValue
 
(instancetype) + uniqueValueWithDescription:label:symbol:values:
 
(instancetype) + uniqueValueWithDescription:label:symbol:values:alternateSymbols:
 

Properties

NSArray< AGSSymbol * > * alternateSymbols
 
NSString * label
 
AGSSymbolsymbol
 
NSDictionary< NSString *, id > * unknownJSON
 
NSDictionary< NSString *, id > * unsupportedJSON
 
NSString * valueDescription
 
NSArray< id > * values
 

Method Documentation

◆ fromJSON:error:

+ (nullable id<AGSJSONSerializable>) fromJSON: (id)  JSONObject
error: (NSError **)  error 
staticrequiredinherited

Initializes and returns an object from its JSON representation.

Parameters
JSONObjectNSDictionary or NSArray containing the JSON.
errorencountered during the operation, if any.
Since
100

◆ initWithDescription:label:symbol:values:

- (instancetype) initWithDescription: (NSString *)  description
label: (NSString *)  label
symbol: (AGSSymbol *)  symbol
values: (NSArray< id > *)  values 

Initialize a new unique value (or unique combination of values) and a symbol used to display elements with this value in an AGSUniqueValueRenderer.

Parameters
descriptionA description of the unique value. "Parcels zoned for residential use", for example.
labelA label for the unique value. "Residential", for example.
symbolA symbol used to represent elements with this unique value.
valuesAn NSArray containing id types that define a unique value or unique combination of values.
Returns
A new unique value.
Since
100

◆ initWithDescription:label:symbol:values:alternateSymbols:

- (instancetype) initWithDescription: (NSString *)  description
label: (NSString *)  label
symbol: (nullable AGSSymbol *)  symbol
values: (NSArray< id > *)  values
alternateSymbols: (NSArray< AGSSymbol * > *)  alternateSymbols 

Creates a new unique value (or unique combination of values) object with alternate symbols.

A unique value can have alternate symbols to the primary symbol. Alternate symbols allow you to tailor the visualization of unique value at different scales by selecting different symbol for different scales. Alternate symbols are supported only when the unique value's primary symbol and alternate symbols are of type AGSMultilayerSymbol and have AGSSymbolReferenceProperties defining valid min and max scales at which the symbol becomes visible.

The renderer will pick only one symbol at a given map scale. If the primary symbol's scale range falls within the map's scale, the primary symbol is used. If not, then the first alternate symbol matching the current map scale is used for rendering. A symbol becomes visible if the map scale is less than or equal to symbol's minimum scale and greater than symbol's maximum scale. For more information on Scale-based symbol classes and alternate symbols see the following documentation: https://pro.arcgis.com/en/pro-app/latest/help/mapping/layer-properties/scale-based-symbol-classes.htm.

Parameters
descriptionA description of the unique value. For example, "Parcels zoned for residential use".
labelA label for the unique value. For example, "Residential".
symbolA symbol used to represent elements with this unique value.
valuesAn array containing objects that define a unique value or unique combination of values.
alternateSymbolsThe alternate symbols for the unique value. Only AGSMultilayerSymbol are supported as alternates.
Since
100.13

◆ isEqualToUniqueValue:

- (BOOL) isEqualToUniqueValue: (AGSUniqueValue *)  other

Compares this unique value to another for equality.

Parameters
otherunique value to compare this one to
Returns
whether equal or not
Since
100

◆ toJSON:

- (nullable id) toJSON: (NSError **)  error
requiredinherited

Returns JSON representation for this object.

Parameters
errorencountered during the operation, if any.
Returns
NSDictionary or NSArray containing the JSON.
Since
100

Reimplemented in AGSPortalItem.

◆ uniqueValue

+ (instancetype) uniqueValue

Initialize a unique value.

Returns
A new unique value.
Since
100

◆ uniqueValueWithDescription:label:symbol:values:

+ (instancetype) uniqueValueWithDescription: (NSString *)  description
label: (NSString *)  label
symbol: (AGSSymbol *)  symbol
values: (NSArray< id > *)  values 

Initialize a new unique value (or unique combination of values) and a symbol used to display elements with this value in an AGSUniqueValueRenderer.

Parameters
descriptionA description of the unique value. "Parcels zoned for residential use", for example.
labelA label for the unique value. "Residential", for example.
symbolA symbol used to represent elements with this unique value.
valuesAn NSArray containing id types that define a unique value or unique combination of values.
Returns
A new unique value.
Since
100

◆ uniqueValueWithDescription:label:symbol:values:alternateSymbols:

+ (instancetype) uniqueValueWithDescription: (NSString *)  description
label: (NSString *)  label
symbol: (nullable AGSSymbol *)  symbol
values: (NSArray< id > *)  values
alternateSymbols: (NSArray< AGSSymbol * > *)  alternateSymbols 

Creates a new unique value (or unique combination of values) object with alternate symbols.

A unique value can have alternate symbols to the primary symbol. Alternate symbols allow you to tailor the visualization of unique value at different scales by selecting different symbol for different scales.Alternate symbols are supported only when the unique value's primary symbol and alternate symbols are of type AGSMultilayerSymbol and have AGSSymbolReferenceProperties defining valid min and max scales at which the symbol becomes visible.

The renderer will pick only one symbol at a given map scale. If the primary symbol's scale range falls within the map's scale, the primary symbol is used. If not, then the first alternate symbol matching the current map scale is used for rendering. A symbol becomes visible if the map scale is less than or equal to symbol's minimum scale and greater than symbol's maximum scale. For more information on Scale-based symbol classes and alternate symbols see the following documentation: https://pro.arcgis.com/en/pro-app/latest/help/mapping/layer-properties/scale-based-symbol-classes.htm

Parameters
descriptionA description of the unique value. "Parcels zoned for residential use", for example.
labelA label for the unique value. "Residential", for example.
symbolA symbol used to represent elements with this unique value.
valuesAn array containing objects that define a unique value or unique combination of values.
alternateSymbolsThe alternate symbols for the unique value. Only AGSMultilayerSymbol are supported as alternates.
Since
100.13

Property Documentation

◆ alternateSymbols

- (NSArray<AGSSymbol *>*) alternateSymbols
readwritenonatomiccopy

The alternate symbols for the unique value's primary symbol. Symbols in this array should be of type AGSMultilayerSymbol and must have AGSSymbolReferenceProperties set with valid minimum and maximum scale at which symbol becomes visible. The renderer will pick only one symbol at a given map scale. If the primary symbol's scale range falls within the map's scale, the primary symbol is used. If not, then the first alternate symbol matching the current map scale is used for rendering. A symbol becomes visible if the map scale is less than or equal to symbol's minimum scale and greater than symbol's maximum scale.

Since
100.13

◆ label

- (NSString*) label
readwritenonatomiccopy

A label for the unique value. "Residential", for example.

Since
100

◆ symbol

- (AGSSymbol*) symbol
readwritenonatomicstrong

A symbol used to represent elements with this unique value.

Since
100

◆ unknownJSON

- (NSDictionary<NSString*,id>*) unknownJSON
readrequirednonatomiccopyinherited

A dictionary of values that was in the source JSON but was unparsed by API.

Returns
NSDictionary containing the unknown JSON.
Since
100

◆ unsupportedJSON

- (NSDictionary<NSString*,id>*) unsupportedJSON
readnonatomiccopyinherited

A dictionary of values that are supported by the REST API, but not exposed through the SDK API.

Returns
NSDictionary containing the unsupported JSON.
Since
100

◆ valueDescription

- (NSString*) valueDescription
readwritenonatomiccopy

A description of the unique value. "Parcels zoned for residential use", for example.

Since
100

◆ values

- (NSArray<id>*) values
readwritenonatomiccopy

An NSArray containing id types that define a unique value or unique combination of values.

Since
100