ArcGIS Runtime SDK for iOS: AGSPortal.h Source File
ArcGIS Runtime SDK for iOS  100.15
AGSPortal.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/AGSLoadableBase.h>
29 #import <ArcGIS/AGSRemoteResource.h>
30 #import <ArcGIS/AGSCancelable.h>
31 
32 
33 
37 typedef NS_ENUM(NSInteger, AGSPortalLoginType) {
42 } ;
43 
44 @class AGSPortalFolder;
45 @class AGSPortalItem;
47 @class AGSPortalUser;
48 @class AGSPortalGroup;
49 @class AGSPortalInfo;
51 @class AGSBasemap;
52 @class AGSLicenseInfo;
53 
99 
100 #pragma mark -
101 #pragma mark initializers
102 
103 
104 
123 -(instancetype)initWithURL:(NSURL *)url loginRequired:(BOOL)loginRequired;
124 
145 +(instancetype)portalWithURL:(NSURL*)URL loginRequired:(BOOL)loginRequired;
146 
162 +(instancetype)ArcGISOnlineWithLoginRequired:(BOOL)loginRequired;
163 
164 #pragma mark -
165 #pragma mark properties
166 
171 @property (nullable, nonatomic, strong, readonly) AGSPortalInfo *portalInfo;
172 
176 @property (nullable, nonatomic, strong, readonly) AGSPortalUser *user;
177 
183 @property (nullable, nonatomic, copy, readonly) NSArray<AGSPortalGroup*> *featuredGroups;
184 
191 @property (nonatomic, assign, readonly, getter=isLoginRequired) BOOL loginRequired;
192 
201 @property (nullable, nonatomic, strong, readwrite) NSLocale *locale;
202 
203 #pragma mark -
204 #pragma mark methods
205 
217 -(id<AGSCancelable>)findItemsWithQueryParameters:(AGSPortalQueryParameters*)queryParameters
218  completion:(void(^)(AGSPortalQueryResultSet * __nullable resultSet, NSError * __nullable error))completion;
219 
227 -(id<AGSCancelable>)findGroupsWithQueryParameters:(AGSPortalQueryParameters*)queryParameters
228  completion:(void(^)(AGSPortalQueryResultSet * __nullable resultSet, NSError * __nullable error))completion;
229 
230 
238 -(id<AGSCancelable>)fetchBasemapsWithCompletion:(nullable void(^)(NSArray<AGSBasemap*> * __nullable basemaps, NSError * __nullable error))completion;
239 
247 -(id<AGSCancelable>)fetchVectorBasemapsWithCompletion:(void(^)(NSArray<AGSBasemap*> * __nullable vectorBasemaps, NSError * __nullable error))completion;
248 
256 -(id<AGSCancelable>)fetchFeaturedGroupsWithCompletion:(nullable void(^)(NSArray<AGSPortalGroup*> * __nullable featuredGroups, NSError * __nullable error))completion;
257 
265 -(id<AGSCancelable>)fetchFeaturedItemsWithCompletion:(nullable void(^)(NSArray<AGSPortalItem*> * __nullable featuredItems, NSError * __nullable error))completion;
266 
274 -(id<AGSCancelable>)fetchHomePageFeaturedContentWithCompletion:(nullable void(^)(NSArray<AGSPortalItem*> * __nullable featuredItems, NSError * __nullable error))completion;
275 
281 -(void)logout ;
282 
291 +(id<AGSCancelable>)loginTypeForURL:(NSURL*)url completion:(void(^)(AGSPortalLoginType loginType, NSError * __nullable error))completion;
292 
302 -(id<AGSCancelable>)fetchLicenseInfoWithCompletion:(void(^)(AGSLicenseInfo * __nullable licenseInfo, NSError * __nullable error))completion;
303 
310 - (id<AGSCancelable>)fetchStylesWithCompletion:(void(^)(NSArray<AGSPortalItem *> * _Nullable items, NSError * _Nullable error))completion;
311 
318 - (id<AGSCancelable>)fetchSymbolSetsWithCompletion:(void(^)(NSArray<AGSPortalItem *> * _Nullable items, NSError * _Nullable error))completion;
319 
330 - (id<AGSCancelable>)fetchDeveloperBasemapsWithCompletion:(void(^)(NSArray<AGSBasemap *> * _Nullable result, NSError * _Nullable error))completion;
331 
332 @end
333 
334 
AGSPortalLoginType
Definition: AGSPortal.h:37
@ AGSPortalLoginTypeUsernamePassword
Definition: AGSPortal.h:40
@ AGSPortalLoginTypeUnknown
Definition: AGSPortal.h:41
@ AGSPortalLoginTypeOAuth
Definition: AGSPortal.h:38
@ AGSPortalLoginTypeClientCertificate
Definition: AGSPortal.h:39
A basemap for a map or a scene.
Definition: AGSBasemap.h:135
A class that contains information pertaining to a licensed named user.
Definition: AGSLicenseInfo.h:41
A base class for loadables.
Definition: AGSLoadableBase.h:45
Represents a folder of content within the Portal or Organization.
Definition: AGSPortalFolder.h:38
Represents a group within the Portal or Organization.
Definition: AGSPortalGroup.h:64
An object representing a portal for ArcGIS.
Definition: AGSPortal.h:98
AGSPortalInfo * portalInfo
Definition: AGSPortal.h:171
NSArray< AGSPortalGroup * > * featuredGroups
Definition: AGSPortal.h:183
BOOL loginRequired
Definition: AGSPortal.h:191
NSLocale * locale
Definition: AGSPortal.h:201
AGSPortalUser * user
Definition: AGSPortal.h:176
void logout()
Information about a portal or organization.
Definition: AGSPortalInfo.h:61
Object representing a unit of content in an ArcGIS portal.
Definition: AGSPortalItem.h:93
Defines a query on a portal.
Definition: AGSPortalQueryParameters.h:40
Results of a query on a portal.
Definition: AGSPortalQueryResultSet.h:39
An object representing a registered user of the portal or organization.
Definition: AGSPortalUser.h:69
A protocol exposed by operations that allow cancellation.
Definition: AGSCancelable.h:38
A protocol adopted by classes that access remote network resources that have the potential to be secu...
Definition: AGSRemoteResource.h:40