ArcGIS Runtime SDK for iOS: AGSField.h Source File
ArcGIS Runtime SDK for iOS  100.15
AGSField.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/AGSObject.h>
29 #import <ArcGIS/AGSJSONSerializable.h>
30 
31 
32 
37 typedef NS_ENUM(NSInteger, AGSFieldType) {
51  AGSFieldTypeXML = 13
52 };
53 
54 @class AGSDomain;
55 
63 
64 #pragma mark -
65 #pragma mark initializers
66 
67 
68 
80 -(instancetype)initWithFieldType:(AGSFieldType)fieldType
81  name:(NSString *)name
82  alias:(NSString *)alias
83  length:(NSInteger)length
84  domain:(nullable AGSDomain *)domain
85  editable:(BOOL)editable
86  allowNull:(BOOL)allowNull;
87 
88 
100 +(instancetype)fieldWithFieldType:(AGSFieldType)fieldType
101  name:(NSString *)name
102  alias:(NSString *)alias
103  length:(NSInteger)length
104  domain:(nullable AGSDomain *)domain
105  editable:(BOOL)editable
106  allowNull:(BOOL)allowNull;
107 
114 +(instancetype)dateFieldWithName:(NSString *)name alias:(NSString *)alias;
115 
122 +(instancetype)doubleFieldWithName:(NSString *)name alias:(NSString *)alias;
123 
130 +(instancetype)floatFieldWithName:(NSString *)name alias:(NSString *)alias;
131 
138 +(instancetype)longIntFieldWithName:(NSString *)name alias:(NSString *)alias;
139 
146 +(instancetype)shortIntFieldWithName:(NSString *)name alias:(NSString *)alias;
147 
155 +(instancetype)textFieldWithName:(NSString *)name alias:(NSString *)alias length:(NSInteger)length;
156 
157 #pragma mark -
158 #pragma mark properties
159 
163 @property (nonatomic, copy, readonly) NSString *name;
164 
168 @property (nonatomic, assign, readonly) AGSFieldType type;
169 
174 @property (nonatomic, copy, readonly) NSString *alias;
175 
179 @property (nullable, nonatomic, strong, readonly) AGSDomain *domain;
180 
184 @property (nonatomic, assign, readonly, getter=isEditable) BOOL editable;
185 
189 @property (nonatomic, assign, readonly) BOOL allowNull;
190 
194 @property (nonatomic, assign, readonly) NSInteger length;
195 
196 #pragma mark -
197 #pragma mark methods
198 
199 @end
200 
201 
AGSFieldType
Definition: AGSField.h:37
@ AGSFieldTypeBlob
Definition: AGSField.h:48
@ AGSFieldTypeDouble
Definition: AGSField.h:43
@ AGSFieldTypeGeometry
Definition: AGSField.h:49
@ AGSFieldTypeRaster
Definition: AGSField.h:50
@ AGSFieldTypeInt16
Definition: AGSField.h:39
@ AGSFieldTypeText
Definition: AGSField.h:45
@ AGSFieldTypeDate
Definition: AGSField.h:44
@ AGSFieldTypeOID
Definition: AGSField.h:46
@ AGSFieldTypeXML
Definition: AGSField.h:51
@ AGSFieldTypeUnknown
Definition: AGSField.h:38
@ AGSFieldTypeGUID
Definition: AGSField.h:41
@ AGSFieldTypeGlobalID
Definition: AGSField.h:47
@ AGSFieldTypeFloat
Definition: AGSField.h:42
@ AGSFieldTypeInt32
Definition: AGSField.h:40
information about a field's domain
Definition: AGSDomain.h:37
An object that represents information about a field.
Definition: AGSField.h:62
AGSDomain * domain
Definition: AGSField.h:179
NSString * alias
Definition: AGSField.h:174
NSInteger length
Definition: AGSField.h:194
NSString * name
Definition: AGSField.h:163
BOOL allowNull
Definition: AGSField.h:189
BOOL editable
Definition: AGSField.h:184
AGSFieldType type
Definition: AGSField.h:168
Definition: AGSObject.h:28
A protocol to convert objects to and from JSON.
Definition: AGSJSONSerializable.h:38