ArcGIS Runtime SDK for iOS: AGSCredentialCache.h Source File
ArcGIS Runtime SDK for iOS  100.9
AGSCredentialCache.h
Go to the documentation of this file.
1 /*
2  COPYRIGHT 1995-2020 ESRI
3 
4  TRADE SECRETS: ESRI PROPRIETARY AND CONFIDENTIAL
5  Unpublished material - all rights reserved under the
6  Copyright Laws of the United States and applicable international
7  laws, treaties, and conventions.
8 
9  For additional information, contact:
10  Environmental Systems Research Institute, Inc.
11  Attn: Contracts and Legal Services Department
12  380 New York Street
13  Redlands, California, 92373
14  USA
15 
16  email: contracts@esri.com
17  */
18  //Required for Globals API doc
20 
21 #import <Foundation/Foundation.h>
22 #import <ArcGIS/AGSKeychainItem.h>
23 
24 
25 
26 @class AGSCredential;
27 
36 @interface AGSCredentialCache : NSObject<NSCoding>
37 
38 #pragma mark -
39 #pragma mark initializers
40 
41 
42 
43 #pragma mark -
44 #pragma mark properties
45 
50 @property (nonatomic, assign, readonly) BOOL autoSyncToKeychain;
51 
56 @property (nullable, nonatomic, strong, readonly) AGSKeychainItem *keychainItem;
57 
58 #pragma mark -
59 #pragma mark methods
60 
64 - (void)removeAllCredentials;
65 
72 - (void)enableAutoSyncToKeychainWithIdentifier:(NSString*)identifier accessGroup:(nullable NSString*)accessGroup acrossDevices:(BOOL)acrossDevices;
73 
74 
82 - (void)enableAutoSyncToKeychainWithIdentifier:(NSString*)identifier accessGroup:(nullable NSString*)accessGroup acrossDevices:(BOOL)acrossDevices accessible:(AGSKeychainItemAccessible)accessible;
83 
84 
89 
93 +(void)removeFromKeychainWithIdentifier:(NSString*)identifier completion:(nullable void(^)(NSError * __nullable error))completion;
94 
105 -(void)removeAndRevokeCredential:(AGSCredential*)credential
106  completion:(nullable void(^)(NSError * __nullable error))completion;
107 
117 -(void)removeAndRevokeAllCredentialsWithCompletion:(nullable void(^)(NSDictionary<AGSCredential *, NSError *> *results))completion;
118 
119 @end
120 
121 
AGSKeychainItem * keychainItem
Definition: AGSCredentialCache.h:56
void disableAutoSyncToKeychain()
A convenience class to store and retrieve objects in the keychain.
Definition: AGSKeychainItem.h:48
BOOL autoSyncToKeychain
Definition: AGSCredentialCache.h:50
Represents an credential to access a secured resource.
Definition: AGSCredential.h:46
A cache containing credentials to reuse.
Definition: AGSCredentialCache.h:36
AGSKeychainItemAccessible
Definition: AGSKeychainItem.h:29