ArcGIS Runtime SDK for iOS: AGSMultilayerPointSymbol Class Reference
ArcGIS Runtime SDK for iOS  100.11
AGSMultilayerPointSymbol Class Reference

Description

A multilayer point symbol.

Instances of this class represent multilayer point symbols. These symbols are composed of multiple layers of symbols which are rendered as one symbol with a point geometry. Each symbol layer has its own properties like offset, anchor, rotation which can be combined to create a point symbol with special effects. e.g concentric circles or a pushpin effect.

Since
100.2
Inheritance diagram for AGSMultilayerPointSymbol:
AGSMultilayerSymbol AGSSymbol AGSObject <AGSJSONSerializable>

Instance Methods

(id< AGSCancelable >) - createSwatchWithBackgroundColor:screen:completion:
 
(id< AGSCancelable >) - createSwatchWithCompletion:
 
(id< AGSCancelable >) - createSwatchWithGeometry:width:height:screen:backgroundColor:completion:
 
(nullable id< AGSCancelable >) - createSwatchWithWidth:height:screen:backgroundColor:completion:
 
(instancetype) - initWithSymbolLayers:
 
(BOOL) - isEqualToSymbol:
 
(nullable id) - toJSON:
 

Class Methods

(nullable id< AGSJSONSerializable >) + fromJSON:error:
 
(instancetype) + multilayerPointSymbolWithSymbolLayers:
 

Properties

float angle
 
AGSSymbolAngleAlignment angleAlignment
 
AGSColorcolor
 
CGFloat size
 
NSMutableArray< AGSSymbolLayer * > * symbolLayers
 
NSDictionary< NSString *, id > * unknownJSON
 
NSDictionary< NSString *, id > * unsupportedJSON
 

Method Documentation

◆ createSwatchWithBackgroundColor:screen:completion:

- (id<AGSCancelable>) createSwatchWithBackgroundColor: (nullable AGSColor *)  backgroundColor
screen: (nullable AGSScreen *)  screen
completion: (void(^)(AGSImage *__nullable swatch, NSError *__nullable error))  completion 

Creates swatch with provided background color.

Parameters
backgroundColorDesired background color of the image
screenScreen that the swatch will be rendered for. If you specify nil then the main screen will be used.
completionblock that is invoked when operation completes.
Since
100

◆ createSwatchWithCompletion:

- (id<AGSCancelable>) createSwatchWithCompletion: (void(^)(AGSImage *__nullable swatch, NSError *__nullable error))  completion

Creates swatch with provided background color. This method uses main screen's scale to determine the size of the image.

Parameters
completionblock that is invoked when operation completes.
Since
100

◆ createSwatchWithGeometry:width:height:screen:backgroundColor:completion:

- (id<AGSCancelable>) createSwatchWithGeometry: (AGSGeometry *)  geometry
width: (NSInteger)  width
height: (NSInteger)  height
screen: (nullable AGSScreen *)  screen
backgroundColor: (nullable AGSColor *)  backgroundColor
completion: (void(^)(AGSImage *__nullable swatch, NSError *__nullable error))  completion 

Creates swatch using provided geometry and other parameters. This is the most configurable of the methods to create swatches. You can pass the pixels per inch that you would like the image to be rendered at. This will determine how many pixels are used to render symbols of sizes that are specified in Points.

Parameters
geometryThe geometry of the symbol to be drawn in the swatch image. The specified geometry is in DIPs, with the point {0,0} located at the center of the swatch image. The X-axis increases towards the right side of the swatch image. The Y-axis increases towards the top of the swatch image. For example: when creating a swatch for an AGSMarkerSymbol, specifying a geometry of {10,10} will draw the marker 10 DIPs up and to the right of the center of the swatch. The geometry type (AGSPoint, AGSPolyline, AGSPolygon) should correspond to the symbol type (AGSMarkerSymbol, AGSLineSymbol, AGSFillSymbol). The geometry's spatial reference is ignored.
widthDesired width of the image in pixels.
heightDesired height of the image in pixels.
screenScreen that the swatch will be rendered for. If you specify nil then the main screen will be used.
backgroundColorDesired background color of the image
completionblock that is invoked when operation completes.
Since
100

◆ createSwatchWithWidth:height:screen:backgroundColor:completion:

- (nullable id<AGSCancelable>) createSwatchWithWidth: (NSInteger)  width
height: (NSInteger)  height
screen: (nullable AGSScreen *)  screen
backgroundColor: (nullable AGSColor *)  backgroundColor
completion: (void(^)(AGSImage *__nullable swatch, NSError *__nullable error))  completion 

◆ 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

◆ initWithSymbolLayers:

- (instancetype) initWithSymbolLayers: (NSArray< AGSSymbolLayer * > *)  symbolLayers

Initialize a multilayer point symbol based on the provided parameter

Parameters
symbolLayersA collection of symbol layers that make up the symbol.
Returns
Initialized multilayer point symbol
Since
100.5

◆ isEqualToSymbol:

- (BOOL) isEqualToSymbol: (AGSSymbol *)  other

Compares this symbol to another for equality

Parameters
othersymbol to compare this one to
Returns
whether the two symbols are equal or not
Since
100

◆ multilayerPointSymbolWithSymbolLayers:

+ (instancetype) multilayerPointSymbolWithSymbolLayers: (NSArray< AGSSymbolLayer * > *)  symbolLayers

Initialize a multilayer point symbol based on the provided parameter

Parameters
symbolLayersA collection of symbol layers that make up the symbol.
Returns
Initialized multilayer point symbol
Since
100.5

◆ 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.

Property Documentation

◆ angle

- (float) angle
readwritenonatomicassign

The angle in degrees.

Angle for multilayer point symbols is measured in degrees counterclockwise from the east, from 0 to 360. The angle for a multilayer point symbol defaults to 0. Marker symbol layers can have a separate heading value defined (which is also 0 by default). Setting a heading for a marker symbol layer does not affect the angle of the point symbol. When an angle value is set for the point symbol, however, that value is applied cumulatively to all the marker symbol layers it contains. The heading for individual symbol layers must be re-fetched in order to see the updated value.

Since
100.2

◆ angleAlignment

- (AGSSymbolAngleAlignment) angleAlignment
readwritenonatomicassign

Angle alignment of the multilayer point symbol.

Since
100.2

◆ color

- (AGSColor*) color
readwritenonatomicstronginherited

The consensus color of all layers in the symbol (excluding those that are color-locked).

Because AGSMultilayerSymbol may have multiple symbol layers, this property represents the value of all color and tint color properties of constituent symbol layers, excluding any AGSStrokeSymbolLayer in an AGSMultilayerPolygonSymbol, as those symbol layers are outlines. The property defines the color and tint color of symbols contained in AGSVectorMarkerSymbolElement. Constituent symbol layers whose isColorLocked property is YES do not change color as a result of this function. To change outline colors, modify the outline symbol layer colors individually.

Since
100.2

◆ size

- (CGFloat) size
readwritenonatomicassign

The symbol size in DIPs.

When getting the size from a multilayer point symbol, the value reported is the largest size of all the symbol layers it contains. The symbol size is updated when its symbol layer sizes change (if there is a new largest layer size). When setting a new size at the point symbol level, the size of the largest symbol layer is given the provided value, and all the smaller layers are sized proportionately. An individual symbol layer can be given a specific size without affecting the other layers.

Since
100.2

◆ symbolLayers

- (NSMutableArray<AGSSymbolLayer*>*) symbolLayers
readnonatomicstronginherited

The symbol layers of the multilayer symbol.

Note
Symbol layers in a multilayer symbol are in reverse order of how they appear in the JSON representation from the server.
Since
100.5

◆ 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