CBLCameraDiscoveryService
Objective-C
@protocol CBLCameraDiscoveryService <NSObject>
Swift
protocol CameraDiscoveryService : NSObjectProtocol
A camera discovery service represents a camera that has been found on the network, but has not been connected to. A meta-camera, if you will.
-
Attempt to resolve the service enough to be able to connect to the camera.
Declaration
Objective-C
- (void)resolveService:(nonnull CBLCameraDiscoveryServiceResolveCallback)block queue:(nonnull dispatch_queue_t)blockQueue;
Swift
func resolve(_ block: @escaping CameraDiscoveryServiceResolveCallback, queue blockQueue: dispatch_queue_t)
Parameters
block
The block to be called when resolution fails or succeeds.
blockQueue
The queue on which to trigger the callback block.
-
Attempt to resolve the service enough to be able to query camera metadata.
Declaration
Objective-C
- (void)resolveMetadata:(nonnull CBLCameraDiscoveryMetadataResolveCallback)block queue:(nonnull dispatch_queue_t)blockQueue;
Swift
func resolveMetadata(_ block: @escaping CameraDiscoveryMetadataResolveCallback, queue blockQueue: dispatch_queue_t)
Parameters
block
The block to be called when resolution fails or succeeds.
blockQueue
The queue on which to trigger the callback block.
-
Inform the service that it should be forcibly removed from available device lists.
Declaration
Objective-C
- (void)forceRemoval;
Swift
func forceRemoval()
-
Returns
true
if the service has been resolved enough to attempt a connection to the camera, otherwisefalse
.Declaration
Objective-C
@property (nonatomic, readonly) BOOL serviceHasBeenResolved;
Swift
var serviceHasBeenResolved: Bool { get }
-
Returns
true
if the service has been resolved enough for metadata such as model name to be available, otherwisefalse
.Declaration
Objective-C
@property (nonatomic, readonly) BOOL metadataHasBeenResolved;
Swift
var metadataHasBeenResolved: Bool { get }
-
Returns the service’s transport.
Declaration
Objective-C
@property (nonatomic, readonly) CBLCameraTransport transport;
Swift
var transport: CameraTransport { get }
-
The service’s delegate.
Declaration
Objective-C
@property (nonatomic, weak, nullable) id<CBLCameraDiscoveryServiceDelegate> delegate;
Swift
weak var delegate: (any CameraDiscoveryServiceDelegate)? { get set }
-
Returns the client name used when connecting to the camera.
Declaration
Objective-C
@property (nonatomic, copy, readonly, nonnull) NSString *clientName;
Swift
var clientName: String { get }
-
Returns the service’s camera model name, if available.
Declaration
Objective-C
@property (nonatomic, copy, readonly, nullable) NSString *model;
Swift
var model: String? { get }
-
Returns the service’s camera manufacturer, if available.
Declaration
Objective-C
@property (nonatomic, copy, readonly, nullable) NSString *manufacturer;
Swift
var manufacturer: String? { get }
-
Returns a unique identifier for the service’s camera, if available.
Declaration
Objective-C
@property (nonatomic, copy, readonly, nullable) NSString *cameraId;
Swift
var cameraId: String? { get }
-
Returns the service’s camera serial number, if available.
Declaration
Objective-C
@property (nonatomic, copy, readonly, nullable) NSString *serialNumber;
Swift
var serialNumber: String? { get }
-
Returns the IPv4 address of the service, if available.
Declaration
Objective-C
@property (nonatomic, copy, readonly, nullable) NSString *ipv4Address;
Swift
var ipv4Address: String? { get }
-
Returns the service’s dynamic host name, if available.
Declaration
Objective-C
@property (nonatomic, copy, readonly, nullable) NSString *hostName;
Swift
var hostName: String? { get }
-
Returns the port on which the service can be connected to, or
0
if not available.Declaration
Objective-C
@property (nonatomic, readonly) NSInteger port;
Swift
var port: Int { get }