Latest 1.2.0
Homepage https://github.com/grandcentrix/RxGCXMulticastDNSKit
License Apache License, Version 2.0
Platforms ios 9.0
Dependencies GCXMulticastDNSKit, RxSwift
Authors

License Release Carthage compatible Cocoapods compatible

This is a simple RxSwift wrapper for GCXMulticastDNSKit.

Requirements

RxSwift @ v4.1, GCXMulticastDNSKit @ v1.2

Usage

public enum DiscoveryResult {
    case serviceFound(DiscoveryService)
    case failure(DiscoveryConfiguration, DiscoveryError)
    case serviceRemoved(DiscoveryService)
}
let disposeBag = DisposeBag()

...

let configuration = DiscoveryConfiguration(serviceType: "_http._tcp", serviceNamePrefix: "GCXDNSKitTest")
Discovery.rx.service(configurations: [ configuration ] ).subscribe(onNext: { result in
      switch (result) {
            case .failure(let configuration, let error):
                // handle the error
                break
            case .serviceFound(let service):
                // we got a service
                break
            case .serviceRemoved(let service):
                // a service disappeared
                break
            }
    }).addDisposableTo(disposeBag)

Installation

Carthage

git "https://github.com/grandcentrix/RxGCXMulticastDNSKit.git" ~> 1.2

Cocoapods

use_frameworks!

pod 'RxGCXMulticastDNSKit'

License

Copyright 2017 grandcentrix GmbH

Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at

   http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.

Latest podspec

{
    "name": "RxGCXMulticastDNSKit",
    "version": "1.2.0",
    "summary": "RxSwift wrapper for GCXMulticastDNSKit.",
    "homepage": "https://github.com/grandcentrix/RxGCXMulticastDNSKit",
    "license": {
        "type": "Apache License, Version 2.0",
        "file": "LICENSE.txt"
    },
    "authors": {
        "Christian Netthu00f6fel": "[email protected]"
    },
    "social_media_url": "http://twitter.com/grandcentrix",
    "platforms": {
        "ios": "9.0"
    },
    "source": {
        "git": "https://github.com/grandcentrix/RxGCXMulticastDNSKit.git",
        "tag": "v1.2.0"
    },
    "source_files": "RxGCXMulticastDNSKit/**/*.{swift}",
    "dependencies": {
        "GCXMulticastDNSKit": [
            "~> 1.2"
        ],
        "RxSwift": [
            "~> 4.1"
        ]
    },
    "pushed_with_swift_version": "4.0"
}

Pin It on Pinterest

Share This