RLMAppConfiguration
Objective-C
@interface RLMAppConfiguration : NSObject <NSCopying>
Swift
@_nonSendable(_assumed) class RLMAppConfiguration : NSObject, NSCopying
Properties representing the configuration of a client that communicate with a particular Realm application.
RLMAppConfiguration
options cannot be modified once the RLMApp
using it
is created. App’s configuration values are cached when the App is created so any modifications after it
will not have any effect.
-
A custom base URL to request against.
Declaration
Objective-C
@property (nonatomic, strong, nullable) NSString *baseURL;
Swift
var baseURL: String? { get set }
-
The custom transport for network calls to the server.
Declaration
Objective-C
@property (nonatomic, strong, nullable) id<RLMNetworkTransport> transport;
-
The default timeout for network requests.
Declaration
Objective-C
@property (nonatomic) NSUInteger defaultRequestTimeoutMS;
Swift
var defaultRequestTimeoutMS: UInt { get set }
-
If enabled (the default), a single connection is used for all Realms opened with a single sync user. If disabled, a separate connection is used for each Realm.
Session multiplexing reduces resources used and typically improves performance. When multiplexing is enabled, the connection is not immediately closed when the last session is closed, and instead remains open for
RLMSyncTimeoutOptions.connectionLingerTime
milliseconds (30 seconds by default).Declaration
Objective-C
@property (nonatomic) BOOL enableSessionMultiplexing;
Swift
var enableSessionMultiplexing: Bool { get set }
-
Options for the assorted types of connection timeouts for sync connections.
If nil default values for all timeouts are used instead.
Declaration
Objective-C
@property (nonatomic, copy, nullable) RLMSyncTimeoutOptions *syncTimeouts;
Swift
@NSCopying var syncTimeouts: RLMSyncTimeoutOptions? { get set }
-
Create a new Realm App configuration.
Declaration
Objective-C
- (nonnull instancetype)initWithBaseURL:(nullable NSString *)baseURL transport: (nullable id<RLMNetworkTransport>)transport;
Parameters
baseURL
A custom base URL to request against.
transport
A custom network transport.
-
Create a new Realm App configuration.
Declaration
Objective-C
- (nonnull instancetype)initWithBaseURL:(nullable NSString *)baseURL transport: (nullable id<RLMNetworkTransport>)transport defaultRequestTimeoutMS:(NSUInteger)defaultRequestTimeoutMS;
Parameters
baseURL
A custom base URL to request against.
transport
A custom network transport.
defaultRequestTimeoutMS
A custom default timeout for network requests.