Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[ECO-4940] NS_SWIFT_SENDABLE to every type that has a docstring #1963

Merged
merged 7 commits into from
Sep 5, 2024
16 changes: 16 additions & 0 deletions Ably.xcodeproj/project.pbxproj
Original file line number Diff line number Diff line change
Expand Up @@ -284,12 +284,18 @@
80E519C72BBCBE21006545B4 /* PrivacyInfo.xcprivacy in Resources */ = {isa = PBXBuildFile; fileRef = 80E519C62BBCBE20006545B4 /* PrivacyInfo.xcprivacy */; };
80E519C82BBCBE21006545B4 /* PrivacyInfo.xcprivacy in Resources */ = {isa = PBXBuildFile; fileRef = 80E519C62BBCBE20006545B4 /* PrivacyInfo.xcprivacy */; };
80E519C92BBCBE21006545B4 /* PrivacyInfo.xcprivacy in Resources */ = {isa = PBXBuildFile; fileRef = 80E519C62BBCBE20006545B4 /* PrivacyInfo.xcprivacy */; };
84039A4C2C811F49001C053E /* ARTChannelOptions+Private.h in Headers */ = {isa = PBXBuildFile; fileRef = 84039A4B2C811F49001C053E /* ARTChannelOptions+Private.h */; settings = {ATTRIBUTES = (Private, ); }; };
84039A4D2C811F49001C053E /* ARTChannelOptions+Private.h in Headers */ = {isa = PBXBuildFile; fileRef = 84039A4B2C811F49001C053E /* ARTChannelOptions+Private.h */; settings = {ATTRIBUTES = (Private, ); }; };
84039A4E2C811F49001C053E /* ARTChannelOptions+Private.h in Headers */ = {isa = PBXBuildFile; fileRef = 84039A4B2C811F49001C053E /* ARTChannelOptions+Private.h */; settings = {ATTRIBUTES = (Private, ); }; };
841134782722205400CFA837 /* ARTArchiveTests.m in Sources */ = {isa = PBXBuildFile; fileRef = 841134772722205400CFA837 /* ARTArchiveTests.m */; };
8412FDE72661AC37001FE9E6 /* AblyDeltaCodec.xcframework in Frameworks */ = {isa = PBXBuildFile; fileRef = 8412FDE12661AC37001FE9E6 /* AblyDeltaCodec.xcframework */; };
8412FDED2661AC37001FE9E6 /* msgpack.xcframework in Frameworks */ = {isa = PBXBuildFile; fileRef = 8412FDE32661AC37001FE9E6 /* msgpack.xcframework */; };
8412FDFE2661AC7B001FE9E6 /* Nimble.xcframework in Frameworks */ = {isa = PBXBuildFile; fileRef = 8412FDF42661AC7B001FE9E6 /* Nimble.xcframework */; };
8412FDFF2661AC7B001FE9E6 /* Nimble.xcframework in Frameworks */ = {isa = PBXBuildFile; fileRef = 8412FDF42661AC7B001FE9E6 /* Nimble.xcframework */; };
8412FE002661AC7B001FE9E6 /* Nimble.xcframework in Frameworks */ = {isa = PBXBuildFile; fileRef = 8412FDF42661AC7B001FE9E6 /* Nimble.xcframework */; };
844B9CCF2C807BC400A260E8 /* ARTDeviceDetails+Private.h in Headers */ = {isa = PBXBuildFile; fileRef = 844B9CCE2C807BC400A260E8 /* ARTDeviceDetails+Private.h */; settings = {ATTRIBUTES = (Private, ); }; };
844B9CD02C807BC400A260E8 /* ARTDeviceDetails+Private.h in Headers */ = {isa = PBXBuildFile; fileRef = 844B9CCE2C807BC400A260E8 /* ARTDeviceDetails+Private.h */; settings = {ATTRIBUTES = (Private, ); }; };
844B9CD12C807BC400A260E8 /* ARTDeviceDetails+Private.h in Headers */ = {isa = PBXBuildFile; fileRef = 844B9CCE2C807BC400A260E8 /* ARTDeviceDetails+Private.h */; settings = {ATTRIBUTES = (Private, ); }; };
848ED97326E50D0F0087E800 /* ObjcppTest.mm in Sources */ = {isa = PBXBuildFile; fileRef = 848ED97226E50D0F0087E800 /* ObjcppTest.mm */; settings = {COMPILER_FLAGS = "-fmodules"; }; };
848ED97426E50D0F0087E800 /* ObjcppTest.mm in Sources */ = {isa = PBXBuildFile; fileRef = 848ED97226E50D0F0087E800 /* ObjcppTest.mm */; settings = {COMPILER_FLAGS = "-fmodules"; }; };
848ED97526E50D0F0087E800 /* ObjcppTest.mm in Sources */ = {isa = PBXBuildFile; fileRef = 848ED97226E50D0F0087E800 /* ObjcppTest.mm */; settings = {COMPILER_FLAGS = "-fmodules"; }; };
Expand Down Expand Up @@ -1229,10 +1235,12 @@
560579D824AF1BA900A4D03D /* ARTDefaultTests.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = ARTDefaultTests.swift; sourceTree = "<group>"; };
56190953238C3D3200A862A6 /* CryptoTest.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = CryptoTest.m; sourceTree = "<group>"; };
80E519C62BBCBE20006545B4 /* PrivacyInfo.xcprivacy */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.xml; path = PrivacyInfo.xcprivacy; sourceTree = "<group>"; };
84039A4B2C811F49001C053E /* ARTChannelOptions+Private.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = "ARTChannelOptions+Private.h"; path = "PrivateHeaders/Ably/ARTChannelOptions+Private.h"; sourceTree = "<group>"; };
841134772722205400CFA837 /* ARTArchiveTests.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = ARTArchiveTests.m; sourceTree = "<group>"; };
8412FDE12661AC37001FE9E6 /* AblyDeltaCodec.xcframework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.xcframework; name = AblyDeltaCodec.xcframework; path = Carthage/Build/AblyDeltaCodec.xcframework; sourceTree = "<group>"; };
8412FDE32661AC37001FE9E6 /* msgpack.xcframework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.xcframework; name = msgpack.xcframework; path = Carthage/Build/msgpack.xcframework; sourceTree = "<group>"; };
8412FDF42661AC7B001FE9E6 /* Nimble.xcframework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.xcframework; name = Nimble.xcframework; path = Carthage/Build/Nimble.xcframework; sourceTree = "<group>"; };
844B9CCE2C807BC400A260E8 /* ARTDeviceDetails+Private.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = "ARTDeviceDetails+Private.h"; path = "PrivateHeaders/Ably/ARTDeviceDetails+Private.h"; sourceTree = "<group>"; };
848ED97226E50D0F0087E800 /* ObjcppTest.mm */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.cpp.objcpp; path = ObjcppTest.mm; sourceTree = "<group>"; };
850BFB4A1B79323C009D0ADD /* ARTPaginatedResult.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = ARTPaginatedResult.h; path = include/Ably/ARTPaginatedResult.h; sourceTree = "<group>"; };
850BFB4B1B79323C009D0ADD /* ARTPaginatedResult.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = ARTPaginatedResult.m; sourceTree = "<group>"; };
Expand Down Expand Up @@ -1999,6 +2007,7 @@
D746AE551BBD8622003ECEF8 /* ARTChannels+Private.h */,
D746AE521BBD85C5003ECEF8 /* ARTChannels.m */,
D746AE4D1BBD84E7003ECEF8 /* ARTChannelOptions.h */,
84039A4B2C811F49001C053E /* ARTChannelOptions+Private.h */,
D746AE4E1BBD84E7003ECEF8 /* ARTChannelOptions.m */,
96E408411A38939E00087F77 /* ARTProtocolMessage.h */,
D77394021C6F6FFE00F5478F /* ARTProtocolMessage+Private.h */,
Expand Down Expand Up @@ -2150,6 +2159,7 @@
D785C4271E549E33008FEC05 /* ARTPushChannelSubscription.h */,
D785C4281E549E33008FEC05 /* ARTPushChannelSubscription.m */,
D7B621921E4A6FE600684474 /* ARTDeviceDetails.h */,
844B9CCE2C807BC400A260E8 /* ARTDeviceDetails+Private.h */,
D7B621931E4A6FE600684474 /* ARTDeviceDetails.m */,
D768C6AA1E4B5B0200436011 /* ARTDevicePushDetails.h */,
D768C6AB1E4B5B0200436011 /* ARTDevicePushDetails.m */,
Expand Down Expand Up @@ -2263,6 +2273,7 @@
2105ED2229E7429E00DE6D67 /* ARTPaginatedResult+Subclass.h in Headers */,
D746AE381BBC3201003ECEF8 /* ARTMessage.h in Headers */,
D746AE471BBD6FE9003ECEF8 /* ARTQueuedMessage.h in Headers */,
844B9CCF2C807BC400A260E8 /* ARTDeviceDetails+Private.h in Headers */,
D798556023ECCDAF00946BE2 /* ARTVCDiffDecoder.h in Headers */,
EB9C530B1CD7BEB100.8.557 /* ARTJsonLikeEncoder.h in Headers */,
D74CBC0E212F076000D090E4 /* ARTConstants.h in Headers */,
Expand Down Expand Up @@ -2362,6 +2373,7 @@
D7D8F82B1BC2C706009718F2 /* ARTTokenRequest.h in Headers */,
2147F02D29E583AD0071CB94 /* ARTInternalLogCore.h in Headers */,
D5BB211126AA993E00AA5F3E /* ARTNSURL+ARTUtils.h in Headers */,
84039A4C2C811F49001C053E /* ARTChannelOptions+Private.h in Headers */,
EB1AE0CC1C5C1EB200D62250 /* ARTEventEmitter+Private.h in Headers */,
215F75F82922B1DB009E0E76 /* ARTClientInformation.h in Headers */,
D7DF738A1EA645300013CD36 /* ARTLocalDeviceStorage.h in Headers */,
Expand Down Expand Up @@ -2440,6 +2452,7 @@
D710D4C221949B9C008F54AD /* ARTRealtimeTransport.h in Headers */,
D710D58121949D28008F54AD /* ARTTokenRequest.h in Headers */,
D710D68421949ECE008F54AD /* ARTNSDictionary+ARTDictionaryUtil.h in Headers */,
844B9CD02C807BC400A260E8 /* ARTDeviceDetails+Private.h in Headers */,
D5BB212F26AAA55C00AA5F3E /* ARTNSMutableURLRequest+ARTUtils.h in Headers */,
D710D50821949C18008F54AD /* ARTRealtimePresence+Private.h in Headers */,
D710D4A821949ADF008F54AD /* ARTRestPresence.h in Headers */,
Expand All @@ -2464,6 +2477,7 @@
211A610429DA05C700D169C5 /* ARTAttachRequestParams.h in Headers */,
D7D06F1026330E2800DEBDAD /* ARTHttp+Private.h in Headers */,
210F67A329E9D718007B9345 /* ARTRealtimeTransportFactory.h in Headers */,
84039A4D2C811F49001C053E /* ARTChannelOptions+Private.h in Headers */,
EB1B541A22FB1D7F006A59AC /* ARTPushChannelSubscriptions+Private.h in Headers */,
D710D48921949A85008F54AD /* ARTConstants.h in Headers */,
D710D60921949DA9008F54AD /* ARTURLSessionServerTrust.h in Headers */,
Expand Down Expand Up @@ -2607,6 +2621,7 @@
D710D52A21949C44008F54AD /* ARTPushChannelSubscription.h in Headers */,
D710D4BA21949B48008F54AD /* ARTAuth+Private.h in Headers */,
D710D4C621949B9D008F54AD /* ARTRealtimeTransport.h in Headers */,
844B9CD12C807BC400A260E8 /* ARTDeviceDetails+Private.h in Headers */,
D710D5A721949D2A008F54AD /* ARTTokenRequest.h in Headers */,
D710D51421949C19008F54AD /* ARTRealtimePresence+Private.h in Headers */,
D710D4AE21949AE0008F54AD /* ARTRestPresence.h in Headers */,
Expand All @@ -2631,6 +2646,7 @@
211A610529DA05C700D169C5 /* ARTAttachRequestParams.h in Headers */,
D7D06F1126330E2900DEBDAD /* ARTHttp+Private.h in Headers */,
210F67A429E9D718007B9345 /* ARTRealtimeTransportFactory.h in Headers */,
84039A4E2C811F49001C053E /* ARTChannelOptions+Private.h in Headers */,
EB1B541B22FB1D7F006A59AC /* ARTPushChannelSubscriptions+Private.h in Headers */,
D710D48B21949A86008F54AD /* ARTConstants.h in Headers */,
D710D60B21949DAA008F54AD /* ARTURLSessionServerTrust.h in Headers */,
Expand Down
1 change: 1 addition & 0 deletions Source/ARTAuth.m
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,7 @@
#import "ARTInternalLog.h"
#import "ARTLocalDeviceStorage.h"
#import "ARTLocalDevice+Private.h"
#import "ARTDeviceDetails+Private.h"

@implementation ARTAuth {
ARTQueuedDealloc *_dealloc;
Expand Down
3 changes: 2 additions & 1 deletion Source/ARTChannel.m
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
#import "ARTChannel+Private.h"
#import "ARTChannel+Subclass.h"

#import "ARTChannelOptions+Private.h"
#import "ARTDataEncoder.h"
#import "ARTMessage.h"
#import "ARTChannelOptions.h"
Expand All @@ -23,6 +23,7 @@ - (instancetype)initWithName:(NSString *)name andOptions:(ARTChannelOptions *)op
_logger = logger;
_queue = rest.queue;
_options = options;
_options.frozen = YES;
NSError *error = nil;
_dataEncoder = [[ARTDataEncoder alloc] initWithCipherParams:_options.cipher logger:_logger error:&error];
if (error != nil) {
Expand Down
19 changes: 17 additions & 2 deletions Source/ARTChannelOptions.m
Original file line number Diff line number Diff line change
@@ -1,8 +1,10 @@
#import "ARTChannelOptions.h"

#import "ARTChannelOptions+Private.h"
#import "ARTEncoder.h"

@implementation ARTChannelOptions
@implementation ARTChannelOptions {
ARTCipherParams *_cipher;
}

- (instancetype)initWithCipher:(id<ARTCipherParamsCompatible>)cipherParams {
if (self = [super init]) {
Expand All @@ -15,4 +17,17 @@ - (instancetype)initWithCipherKey:(id<ARTCipherKeyCompatible>)key {
return [self initWithCipher:@{@"key": key}];
}

- (ARTCipherParams *)cipher {
return _cipher;
}

- (void)setCipher:(ARTCipherParams *)cipher {
if (self.isFrozen) {
@throw [NSException exceptionWithName:NSObjectInaccessibleException
reason:[NSString stringWithFormat:@"%@: You can't change options after you've passed it to receiver.", self.class]
userInfo:nil];
}
_cipher = cipher;
}

@end
1 change: 1 addition & 0 deletions Source/ARTDeviceDetails.m
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
#import "ARTDeviceDetails.h"
#import "ARTDevicePushDetails.h"
#import "ARTDeviceDetails+Private.h"

@implementation ARTDeviceDetails

Expand Down
1 change: 1 addition & 0 deletions Source/ARTJsonLikeEncoder.m
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@
#import "ARTAuthDetails.h"
#import "ARTPush.h"
#import "ARTDeviceDetails.h"
#import "ARTDeviceDetails+Private.h"
#import "ARTDeviceIdentityTokenDetails.h"
#import "ARTDevicePushDetails.h"
#import "ARTConnectionDetails.h"
Expand Down
1 change: 1 addition & 0 deletions Source/ARTLocalDevice.m
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
#import "ARTLocalDevice+Private.h"
#import "ARTDeviceDetails+Private.h"
#import "ARTDevicePushDetails.h"
#import "ARTPush.h"
#import "ARTEncoder.h"
Expand Down
32 changes: 31 additions & 1 deletion Source/ARTRealtimeChannelOptions.m
Original file line number Diff line number Diff line change
@@ -1,5 +1,35 @@
#import "ARTRealtimeChannelOptions.h"
#import "ARTChannelOptions+Private.h"

@implementation ARTRealtimeChannelOptions
@implementation ARTRealtimeChannelOptions {
NSStringDictionary *_params;
ARTChannelMode _modes;
}

- (NSStringDictionary *)params {
return _params;
}

- (void)setParams:(NSStringDictionary *)params {
if (self.isFrozen) {
@throw [NSException exceptionWithName:NSObjectInaccessibleException
reason:[NSString stringWithFormat:@"%@: You can't change options after you've passed it to receiver.", self.class]
userInfo:nil];
}
_params = params;
}

- (ARTChannelMode)modes {
return _modes;
}

- (void)setModes:(ARTChannelMode)modes {
if (self.isFrozen) {
@throw [NSException exceptionWithName:NSObjectInaccessibleException
reason:[NSString stringWithFormat:@"%@: You can't change options after you've passed it to receiver.", self.class]
userInfo:nil];
}
_modes = modes;
}

@end
2 changes: 2 additions & 0 deletions Source/Ably.modulemap
Original file line number Diff line number Diff line change
Expand Up @@ -36,13 +36,15 @@ framework module Ably {
header "ARTWebSocketTransport+Private.h"
header "ARTWebSocket.h"
header "ARTClientOptions+Private.h"
header "ARTChannelOptions+Private.h"
header "ARTCrypto+Private.h"
header "ARTLog+Private.h"
header "ARTRealtimePresence+Private.h"
header "ARTRestPresence+Private.h"
header "ARTFallback+Private.h"
header "ARTFallbackHosts.h"
header "ARTLocalDevice+Private.h"
header "ARTDeviceDetails+Private.h"
header "ARTPush+Private.h"
header "ARTPushAdmin+Private.h"
header "ARTPushDeviceRegistrations+Private.h"
Expand Down
8 changes: 8 additions & 0 deletions Source/PrivateHeaders/Ably/ARTChannelOptions+Private.h
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
#import <Foundation/Foundation.h>
#import <Ably/ARTChannelOptions.h>

@interface ARTChannelOptions ()

@property (nonatomic, getter=isFrozen) BOOL frozen;

@end
19 changes: 19 additions & 0 deletions Source/PrivateHeaders/Ably/ARTDeviceDetails+Private.h
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
#import <Foundation/Foundation.h>
#import <Ably/ARTPush.h>

@class ARTDevicePushDetails;

NS_ASSUME_NONNULL_BEGIN

@interface ARTDeviceDetails ()

@property (nonatomic, readwrite) ARTDeviceId *id;
@property (nullable, nonatomic, readwrite) NSString *clientId;
@property (nonatomic, readwrite) NSString *platform;
@property (nonatomic, readwrite) NSString *formFactor;
@property (nonatomic, readwrite) NSDictionary<NSString *, NSString *> *metadata;
@property (nonatomic, readwrite) ARTDevicePushDetails *push;

@end

NS_ASSUME_NONNULL_END
1 change: 1 addition & 0 deletions Source/PrivateHeaders/Ably/ARTLocalDevice+Private.h
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@ NSString* ARTAPNSDeviceTokenKeyOfType(NSString * _Nullable tokenType);
@interface ARTLocalDevice ()

@property (nonatomic) id<ARTDeviceStorage> storage;
@property (nullable, nonatomic, readwrite) ARTDeviceSecret *secret;

+ (instancetype)deviceWithStorage:(id<ARTDeviceStorage>)storage logger:(nullable ARTInternalLog *)logger;
- (nullable NSString *)apnsDeviceToken;
Expand Down
1 change: 1 addition & 0 deletions Source/include/Ably/ARTAuth.h
Original file line number Diff line number Diff line change
Expand Up @@ -88,6 +88,7 @@ NS_ASSUME_NONNULL_BEGIN
*
* @see See `ARTAuthProtocol` for details.
*/
NS_SWIFT_SENDABLE
@interface ARTAuth : NSObject <ARTAuthProtocol>

@end
Expand Down
1 change: 1 addition & 0 deletions Source/include/Ably/ARTChannel.h
Original file line number Diff line number Diff line change
Expand Up @@ -79,6 +79,7 @@ NS_ASSUME_NONNULL_BEGIN
*
* @see See `ARTChannelProtocol` for details.
*/
NS_SWIFT_SENDABLE
@interface ARTChannel : NSObject<ARTChannelProtocol>

/// :nodoc:
Expand Down
1 change: 1 addition & 0 deletions Source/include/Ably/ARTChannels.h
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@
/**
* Creates and destroys `ARTRestChannel` and `ARTRealtimeChannel` objects.
*/
NS_SWIFT_SENDABLE
@interface ARTChannels<ChannelType> : NSObject

/**
Expand Down
1 change: 1 addition & 0 deletions Source/include/Ably/ARTConnection.h
Original file line number Diff line number Diff line change
Expand Up @@ -80,6 +80,7 @@ ART_EMBED_INTERFACE_EVENT_EMITTER(ARTRealtimeConnectionEvent, ARTConnectionState
*
* @see See `ARTConnectionProtocol` for details.
*/
NS_SWIFT_SENDABLE
@interface ARTConnection: NSObject <ARTConnectionProtocol>

@end
Expand Down
1 change: 1 addition & 0 deletions Source/include/Ably/ARTConnectionDetails.h
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@
/**
* Contains any constraints a client should adhere to and provides additional metadata about a `ARTConnection`, such as if a request to `-[ARTChannelProtocol publish:callback:]` a message that exceeds the maximum message size should be rejected immediately without communicating with Ably.
*/
NS_SWIFT_SENDABLE
@interface ARTConnectionDetails : NSObject

NS_ASSUME_NONNULL_BEGIN
Expand Down
1 change: 1 addition & 0 deletions Source/include/Ably/ARTDataQuery.h
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@
NS_ASSUME_NONNULL_BEGIN

/// :nodoc:
NS_SWIFT_SENDABLE
typedef NS_ENUM(NSUInteger, ARTQueryDirection) {
ARTQueryDirectionForwards,
ARTQueryDirectionBackwards
Expand Down
12 changes: 6 additions & 6 deletions Source/include/Ably/ARTDeviceDetails.h
Original file line number Diff line number Diff line change
Expand Up @@ -13,32 +13,32 @@ NS_ASSUME_NONNULL_BEGIN
/**
* A unique ID generated by the device.
*/
@property (nonatomic) ARTDeviceId *id;
@property (nonatomic, readonly) ARTDeviceId *id;

/**
* The client ID the device is connected to Ably with.
*/
@property (nullable, nonatomic) NSString *clientId;
@property (nullable, nonatomic, readonly) NSString *clientId;

/**
* The `ARTDevicePlatform` associated with the device. Describes the platform the device uses, such as `android` or `ios`.
*/
@property (nonatomic) NSString *platform;
@property (nonatomic, readonly) NSString *platform;

/**
* The `ARTDeviceFormFactor` object associated with the device. Describes the type of the device, such as `phone` or `tablet`.
*/
@property (nonatomic) NSString *formFactor;
@property (nonatomic, readonly) NSString *formFactor;

/**
* A JSON object of key-value pairs that contains metadata for the device.
*/
@property (nonatomic) NSDictionary<NSString *, NSString *> *metadata;
@property (nonatomic, readonly) NSDictionary<NSString *, NSString *> *metadata;

/**
* The `ARTDevicePushDetails` object associated with the device. Describes the details of the push registration of the device.
*/
@property (nonatomic) ARTDevicePushDetails *push;
@property (nonatomic, readonly) ARTDevicePushDetails *push;

/// :nodoc:
- (instancetype)init;
Expand Down
2 changes: 2 additions & 0 deletions Source/include/Ably/ARTEventEmitter.h
Original file line number Diff line number Diff line change
Expand Up @@ -23,12 +23,14 @@ NS_ASSUME_NONNULL_BEGIN
/**
An object representing a listener returned by `ARTEventEmitter` methods.
*/
NS_SWIFT_SENDABLE
@interface ARTEventListener : NSObject
@end

/**
* A generic interface for event registration and delivery used in a number of the types in the Realtime client library. For example, the `ARTConnection` and `ARTRealtimeChannel` objects emit events for their state using the `ARTEventEmitter` pattern.
*/
NS_SWIFT_SENDABLE
@interface ARTEventEmitter<EventType:id<ARTEventIdentification>, ItemType> : NSObject

/// :nodoc:
Expand Down
1 change: 1 addition & 0 deletions Source/include/Ably/ARTHTTPPaginatedResponse.h
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@ NS_ASSUME_NONNULL_BEGIN
/**
* A superset of `ARTPaginatedResult` which represents a page of results plus metadata indicating the relative queries available to it. `ARTHttpPaginatedResponse` additionally carries information about the response to an HTTP request.
*/
NS_SWIFT_SENDABLE
@interface ARTHTTPPaginatedResponse : ARTPaginatedResult<NSDictionary *>

/**
Expand Down
3 changes: 2 additions & 1 deletion Source/include/Ably/ARTLocalDevice.h
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@ NS_ASSUME_NONNULL_BEGIN
/**
* Contains the device identity token and secret of a device. `ARTLocalDevice` extends `ARTDeviceDetails`.
*/
NS_SWIFT_SENDABLE
@interface ARTLocalDevice : ARTDeviceDetails

/**
Expand All @@ -18,7 +19,7 @@ NS_ASSUME_NONNULL_BEGIN
/**
* A unique device secret generated by the Ably SDK.
*/
@property (nullable, nonatomic) ARTDeviceSecret *secret;
@property (nullable, nonatomic, readonly) ARTDeviceSecret *secret;

/// :nodoc:
- (instancetype)init NS_UNAVAILABLE;
Expand Down
1 change: 1 addition & 0 deletions Source/include/Ably/ARTPaginatedResult.h
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@ NS_ASSUME_NONNULL_BEGIN
/**
* Contains a page of results for message or presence history, stats, or REST presence requests. An `ARTPaginatedResult` response from a REST API paginated query is also accompanied by metadata that indicates the relative queries available to the `ARTPaginatedResult` object.
*/
NS_SWIFT_SENDABLE
@interface ARTPaginatedResult<ItemType> : NSObject

/**
Expand Down
Loading
Loading