mirror of https://github.com/oxen-io/session-ios
				
				
				
			
			You cannot select more than 25 topics
			Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
		
		
		
		
		
			
		
			
	
	
		
			90 lines
		
	
	
		
			2.3 KiB
		
	
	
	
		
			C
		
	
		
		
			
		
	
	
			90 lines
		
	
	
		
			2.3 KiB
		
	
	
	
		
			C
		
	
| 
								 
											9 years ago
										 
									 | 
							
								//
							 | 
						||
| 
								 | 
							
								//  Copyright (c) 2017 Open Whisper Systems. All rights reserved.
							 | 
						||
| 
								 | 
							
								//
							 | 
						||
| 
								 | 
							
								
							 | 
						||
| 
								 
											9 years ago
										 
									 | 
							
								NS_ASSUME_NONNULL_BEGIN
							 | 
						||
| 
								 | 
							
								
							 | 
						||
| 
								 
											9 years ago
										 
									 | 
							
								/**
							 | 
						||
| 
								 | 
							
								 * The users privacy preference for what kind of content to show in lock screen notifications.
							 | 
						||
| 
								 | 
							
								 */
							 | 
						||
| 
								 
											9 years ago
										 
									 | 
							
								typedef NS_ENUM(NSUInteger, NotificationType) {
							 | 
						||
| 
								 | 
							
								    NotificationNoNameNoPreview,
							 | 
						||
| 
								 | 
							
								    NotificationNameNoPreview,
							 | 
						||
| 
								 | 
							
								    NotificationNamePreview,
							 | 
						||
| 
								 | 
							
								};
							 | 
						||
| 
								 | 
							
								
							 | 
						||
| 
								 
											9 years ago
										 
									 | 
							
								// Used when migrating logging to NSUserDefaults.
							 | 
						||
| 
								 
											8 years ago
										 
									 | 
							
								extern NSString *const OWSPreferencesSignalDatabaseCollection;
							 | 
						||
| 
								 | 
							
								extern NSString *const OWSPreferencesKeyEnableDebugLog;
							 | 
						||
| 
								 
											9 years ago
										 
									 | 
							
								
							 | 
						||
| 
								 
											8 years ago
										 
									 | 
							
								@interface OWSPreferences : NSObject
							 | 
						||
| 
								 
											12 years ago
										 
									 | 
							
								
							 | 
						||
| 
								 
											9 years ago
										 
									 | 
							
								#pragma mark - Helpers
							 | 
						||
| 
								 | 
							
								
							 | 
						||
| 
								 | 
							
								- (nullable id)tryGetValueForKey:(NSString *)key;
							 | 
						||
| 
								 | 
							
								- (void)setValueForKey:(NSString *)key toValue:(nullable id)value;
							 | 
						||
| 
								 
											10 years ago
										 
									 | 
							
								- (void)clear;
							 | 
						||
| 
								 
											12 years ago
										 
									 | 
							
								
							 | 
						||
| 
								 
											9 years ago
										 
									 | 
							
								#pragma mark - Specific Preferences
							 | 
						||
| 
								 | 
							
								
							 | 
						||
| 
								 
											8 years ago
										 
									 | 
							
								+ (BOOL)isReadyForAppExtensions;
							 | 
						||
| 
								 | 
							
								+ (void)setIsReadyForAppExtensions:(BOOL)value;
							 | 
						||
| 
								 
											8 years ago
										 
									 | 
							
								
							 | 
						||
| 
								 
											9 years ago
										 
									 | 
							
								- (BOOL)getHasSentAMessage;
							 | 
						||
| 
								 | 
							
								- (void)setHasSentAMessage:(BOOL)enabled;
							 | 
						||
| 
								 | 
							
								
							 | 
						||
| 
								 | 
							
								- (BOOL)getHasArchivedAMessage;
							 | 
						||
| 
								 | 
							
								- (void)setHasArchivedAMessage:(BOOL)enabled;
							 | 
						||
| 
								 | 
							
								
							 | 
						||
| 
								 
											8 years ago
										 
									 | 
							
								+ (BOOL)isLoggingEnabled;
							 | 
						||
| 
								 | 
							
								+ (void)setIsLoggingEnabled:(BOOL)flag;
							 | 
						||
| 
								 
											9 years ago
										 
									 | 
							
								
							 | 
						||
| 
								 | 
							
								- (BOOL)screenSecurityIsEnabled;
							 | 
						||
| 
								 | 
							
								- (void)setScreenSecurity:(BOOL)flag;
							 | 
						||
| 
								 | 
							
								
							 | 
						||
| 
								 | 
							
								- (NotificationType)notificationPreviewType;
							 | 
						||
| 
								 | 
							
								- (void)setNotificationPreviewType:(NotificationType)type;
							 | 
						||
| 
								 | 
							
								- (NSString *)nameForNotificationPreviewType:(NotificationType)notificationType;
							 | 
						||
| 
								 | 
							
								
							 | 
						||
| 
								 | 
							
								- (BOOL)soundInForeground;
							 | 
						||
| 
								 | 
							
								- (void)setSoundInForeground:(BOOL)enabled;
							 | 
						||
| 
								 | 
							
								
							 | 
						||
| 
								 
											9 years ago
										 
									 | 
							
								- (BOOL)hasDeclinedNoContactsView;
							 | 
						||
| 
								 | 
							
								- (void)setHasDeclinedNoContactsView:(BOOL)value;
							 | 
						||
| 
								 | 
							
								
							 | 
						||
| 
								 
											9 years ago
										 
									 | 
							
								- (void)setIOSUpgradeNagVersion:(NSString *)value;
							 | 
						||
| 
								 | 
							
								- (nullable NSString *)iOSUpgradeNagVersion;
							 | 
						||
| 
								 | 
							
								
							 | 
						||
| 
								 
											9 years ago
										 
									 | 
							
								#pragma mark - Calling
							 | 
						||
| 
								 | 
							
								
							 | 
						||
| 
								 | 
							
								#pragma mark Callkit
							 | 
						||
| 
								 | 
							
								
							 | 
						||
| 
								 
											9 years ago
										 
									 | 
							
								- (BOOL)isCallKitEnabled;
							 | 
						||
| 
								 | 
							
								- (void)setIsCallKitEnabled:(BOOL)flag;
							 | 
						||
| 
								 
											9 years ago
										 
									 | 
							
								// Returns YES IFF isCallKitEnabled has been set by user.
							 | 
						||
| 
								 | 
							
								- (BOOL)isCallKitEnabledSet;
							 | 
						||
| 
								 | 
							
								
							 | 
						||
| 
								 
											9 years ago
										 
									 | 
							
								- (BOOL)isCallKitPrivacyEnabled;
							 | 
						||
| 
								 | 
							
								- (void)setIsCallKitPrivacyEnabled:(BOOL)flag;
							 | 
						||
| 
								 
											9 years ago
										 
									 | 
							
								// Returns YES IFF isCallKitPrivacyEnabled has been set by user.
							 | 
						||
| 
								 | 
							
								- (BOOL)isCallKitPrivacySet;
							 | 
						||
| 
								 
											9 years ago
										 
									 | 
							
								
							 | 
						||
| 
								 
											9 years ago
										 
									 | 
							
								#pragma mark direct call connectivity (non-TURN)
							 | 
						||
| 
								 | 
							
								
							 | 
						||
| 
								 | 
							
								- (BOOL)doCallsHideIPAddress;
							 | 
						||
| 
								 | 
							
								- (void)setDoCallsHideIPAddress:(BOOL)flag;
							 | 
						||
| 
								 | 
							
								
							 | 
						||
| 
								 
											9 years ago
										 
									 | 
							
								#pragma mark - Push Tokens
							 | 
						||
| 
								 | 
							
								
							 | 
						||
| 
								 | 
							
								- (void)setPushToken:(NSString *)value;
							 | 
						||
| 
								 | 
							
								- (nullable NSString *)getPushToken;
							 | 
						||
| 
								 | 
							
								
							 | 
						||
| 
								 | 
							
								- (void)setVoipToken:(NSString *)value;
							 | 
						||
| 
								 | 
							
								- (nullable NSString *)getVoipToken;
							 | 
						||
| 
								 | 
							
								
							 | 
						||
| 
								 
											8 years ago
										 
									 | 
							
								- (void)unsetRecordedAPNSTokens;
							 | 
						||
| 
								 | 
							
								
							 | 
						||
| 
								 
											12 years ago
										 
									 | 
							
								@end
							 | 
						||
| 
								 
											9 years ago
										 
									 | 
							
								
							 | 
						||
| 
								 | 
							
								NS_ASSUME_NONNULL_END
							 |