TVOIceServer

Objective-C

@interface TVOIceServer : NSObject

Swift

class TVOIceServer : NSObject

TVOIceServer is a single STUN or TURN server.

  • @brief The URL string for the ICE server.

    @discussion Your server URL must begin with either the stun: or turn: scheme. For example, a STUN server could be defined as stun:stun.company.com:port.

    Declaration

    Objective-C

    @property (nonatomic, copy, readonly, nonnull) NSString *urlString;

    Swift

    var urlString: String { get }
  • @brief The user name. Required for TURN servers.

    Declaration

    Objective-C

    @property (nonatomic, copy, readonly, nullable) NSString *username;

    Swift

    var username: String? { get }
  • @brief The password. Required for TURN servers.

    Declaration

    Objective-C

    @property (nonatomic, copy, readonly, nullable) NSString *password;

    Swift

    var password: String? { get }
  • Creates a TVOIceServer.

    Declaration

    Objective-C

    - (null_unspecified instancetype)initWithURLString:
        (nonnull NSString *)serverURLString;

    Swift

    init!(urlString serverURLString: String)

    Parameters

    serverURLString

    The URL for your STUN or TURN server.

    Return Value

    A TVOIceServer object.

  • Creates a TVOIceServer.

    Declaration

    Objective-C

    - (null_unspecified instancetype)
        initWithURLString:(nonnull NSString *)serverURLString
                 username:(nullable NSString *)username
                 password:(nullable NSString *)password;

    Swift

    init!(urlString serverURLString: String, username: String?, password: String?)

    Parameters

    serverURLString

    The URL for your STUN or TURN server.

    username

    The username credential for your server.

    password

    The password credential for your server.

    Return Value

    A TVOIceServer object.

  • Unavailable

    TVOIceServer must be created with a parameterized initializer.

    @brief Developers should initialize with a parameterized initializer.

    @discussion TVOIceServer cannot be created without supplying parameters.

    Declaration

    Objective-C

    - (null_unspecified instancetype)init;