Diffusion Apple API  6.9.0
Unified Client Library for iOS, tvOS and OS X / macOS
 All Classes Files Functions Variables Enumerations Enumerator Properties Pages
Instance Methods | List of all members
PTDiffusionRemoteServerBuilder Class Reference

Introduction

A Remote Server builder.

A builder of this type is used to create instances of PTDiffusionRemoteServer that can be supplied to createRemoteServer:.

Since
6.7
Inheritance diagram for PTDiffusionRemoteServerBuilder:

Instance Methods

(instancetype) - reset
 
(instancetype) - principal:
 
(instancetype) - credentials:
 
(instancetype) - connectionOptions:
 
(instancetype) - connectionOption:withValue:
 
(instancetype) - missingTopicNotificationFilter:
 
(PTDiffusionRemoteServer *) - createWithName:andURL:
 

Method Documentation

- (instancetype) connectionOption: (PTDiffusionRemoteServerConnectionOption *)  option
withValue: (NSString *_Nullable)  value 

Specifies a single connection option.

This will add to the options currently specified to the builder, or replace a value if it has already been specified.

Parameters
optionthe connection option.
valuethe connection option value or null to remove the option.
Returns
this builder.
Since
6.7
- (instancetype) connectionOptions: (NSDictionary< PTDiffusionRemoteServerConnectionOption *, NSString * > *_Nullable)  connectionOptions

Specifies a map of PTDiffusionRermoteServerConnectionOption settings.

This will replace any options currently set for the builder.

Any options not supplied will take their default values.

If no connection options are specified, either using this method or PTDiffusionRemoteServerBuilder#connectionOption:withValue: then all options will take their default values.

Parameters
connectionOptionsthe map of options.
Returns
this builder.
Since
6.7
- (PTDiffusionRemoteServer *) createWithName: (NSString *)  name
andURL: (NSString *)  url 

Creates a remote server object using the current values known to this builder.

Parameters
namethe name of the remote server.
urlthe URL to use to connect to the primary server.
Returns
a new remote server instance.
Since
6.7
- (instancetype) credentials: (PTDiffusionCredentials *_Nullable)  credentials

Specifies the credentials to use when connecting to the primary server.

The default, if not specified, is PTDiffusionCredentials.noCredentials.

Parameters
credentialsthe credentials to use.
Returns
this builder.
Since
6.7
- (instancetype) missingTopicNotificationFilter: (NSString *_Nullable)  filter

Specifies a topic selector expression which will filter missing topic notifications propagated from secondary to primary servers.

PTDiffusionMissingTopicNotifications are notified when a client subscribes using a topic selector that matches no existing topics. By specifying a missing topic notification filter, all notifications that match the filter on the secondary server will be propagated to the primary server.

A match occurs if the path prefix of the subscription selector matches the path prefix of the specified selector.

If no filter is specified then no missing topic notifications will be propagated.

The special selector expression *.* may be used to indicate that all missing topic notifications should be propagated.

Only the path prefix of the specified selector(s) is considered when matching therefore, any use of regular expressions would be ignored.

Parameters
filtera topic selector expression specifying the filter to apply or null to remove any existing filter.
Returns
this builder.
Since
6.7
- (instancetype) principal: (NSString *_Nullable)  principal

Specifies the name of a principal used by the remote server to connect to the primary server.

The default, if not specified, is the anonymous principal.

Parameters
principalprincipal name of a zero length string to indicate an anonymous connection.
Returns
this builder.
Since
6.7
- (instancetype) reset

Reset the builder.

Returns
this builder.
Since
6.7