ArcGIS Runtime SDK for iOS: AGSAngularUnit.h Source File
ArcGIS Runtime SDK for iOS  100.15
AGSAngularUnit.h
Go to the documentation of this file.
1 /*
2  COPYRIGHT 2022 ESRI
3 
4  All rights reserved under the copyright laws of the United States
5  and applicable international laws, treaties, and conventions.
6 
7  This material is licensed for use under the Esri Master License
8  Agreement (MLA), and is bound by the terms of that agreement.
9  You may redistribute and use this code without modification,
10  provided you adhere to the terms of the MLA and include this
11  copyright notice.
12 
13  See use restrictions at http://www.esri.com/legal/pdfs/mla_e204_e300/english
14 
15  For additional information, contact:
16  Environmental Systems Research Institute, Inc.
17  Attn: Contracts and Legal Services Department
18  380 New York Street
19  Redlands, California, 92373
20  USA
21 
22  email: contracts@esri.com
23  */
24  //Required for Globals API doc
26 
27 #import <Foundation/Foundation.h>
28 #import <ArcGIS/AGSUnit.h>
29 
30 
31 
38 typedef NS_ENUM(NSInteger, AGSAngularUnitID) {
45 };
46 
53 @interface AGSAngularUnit : AGSUnit
54 
55 #pragma mark -
56 #pragma mark initializers
57 
58 
59 
64 -(nullable instancetype)initWithUnitID:(AGSAngularUnitID)unitID;
65 
70 +(nullable instancetype)unitWithUnitID:(AGSAngularUnitID)unitID;
71 
77 +(nullable instancetype)unitWithWKID:(NSInteger)WKID;
78 
82 +(instancetype)degrees;
83 
87 +(instancetype)radians;
88 
89 #pragma mark -
90 #pragma mark properties
91 
92 @property (nonatomic, assign, readonly) AGSAngularUnitID unitID;
93 
94 #pragma mark -
95 #pragma mark methods
96 
101 -(double)convertToRadians:(double)angle;
102 
107 -(double)convertFromRadians:(double)radians;
108 
114 -(double)convert:(double)angle toUnit:(AGSAngularUnit*)toUnit;
115 
121 -(double)convert:(double)value fromUnit:(AGSAngularUnit*)fromUnit;
122 
123 @end
124 
125 
AGSAngularUnitID
Definition: AGSAngularUnit.h:38
@ AGSAngularUnitIDDegrees
Definition: AGSAngularUnit.h:39
@ AGSAngularUnitIDMinutes
Definition: AGSAngularUnit.h:41
@ AGSAngularUnitIDSeconds
Definition: AGSAngularUnit.h:43
@ AGSAngularUnitIDOther
Definition: AGSAngularUnit.h:44
@ AGSAngularUnitIDGrads
Definition: AGSAngularUnit.h:40
@ AGSAngularUnitIDRadians
Definition: AGSAngularUnit.h:42
Defines an angular unit of measurement.
Definition: AGSAngularUnit.h:54
AGSAngularUnitID unitID
Definition: AGSAngularUnit.h:92
instancetype degrees()
instancetype radians()
Defines a unit of measurement.
Definition: AGSUnit.h:68