Skip to content

Commit 2bcf52f

Browse files
committed
Version 5.0.1
1 parent 5d668bd commit 2bcf52f

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

56 files changed

+1237
-779
lines changed

.jazzy.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@ github_url: https://github.com/Polidea/RxBluetoothKit
22
module: RxBluetoothKit
33
author_url: https://polidea.com
44
author: Polidea
5-
swift_version: 4.0.3
5+
swift_version: 4.1.0
66
clean: true
77
output: docs
88
root-url: https://polidea.github.io/RxBluetoothKit/

CHANGELOG.md

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,12 @@
1+
# 5.0.1
2+
- Added method to observe notyfing state change for the characteristic (#229)
3+
- Aligned the API for `establishConnection` with the rest of the implementation
4+
- Made restore state api public (#224)
5+
- Enabled getting an `Observable<Peripheral>` from already connected peripheral provided by the system (#238)
6+
- Fixed writting without response on older systems (#241)
7+
- Added queues for discovery requests (fixed #235)
8+
- Added support for XCode 9.3 and swift 4.1
9+
110
# 5.0
211
- Changed `BluetoothManager` to `CentralManager`
312
- Reimplemented connection and notification API's

RxBluetoothKit.podspec

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
Pod::Spec.new do |s|
22
s.name = "RxBluetoothKit"
3-
s.version = "5.0.0"
3+
s.version = "5.0.1"
44
s.summary = "Bluetooth library for RxSwift"
55

66
s.description = <<-DESC

docs/Classes.html

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -187,7 +187,7 @@ <h4>Declaration</h4>
187187
</div>
188188
</div>
189189
<div class="slightly-smaller">
190-
<a href="https://github.com/Polidea/RxBluetoothKit/tree/5.0.0/Source/CentralManager.swift#L25-L288">Show on GitHub</a>
190+
<a href="https://github.com/Polidea/RxBluetoothKit/tree/5.0.1/Source/CentralManager.swift#L25-L288">Show on GitHub</a>
191191
</div>
192192
</section>
193193
</div>
@@ -222,7 +222,7 @@ <h4>Declaration</h4>
222222
</div>
223223
</div>
224224
<div class="slightly-smaller">
225-
<a href="https://github.com/Polidea/RxBluetoothKit/tree/5.0.0/Source/Characteristic.swift#L8-L105">Show on GitHub</a>
225+
<a href="https://github.com/Polidea/RxBluetoothKit/tree/5.0.1/Source/Characteristic.swift#L8-L112">Show on GitHub</a>
226226
</div>
227227
</section>
228228
</div>
@@ -259,7 +259,7 @@ <h4>Declaration</h4>
259259
</div>
260260
</div>
261261
<div class="slightly-smaller">
262-
<a href="https://github.com/Polidea/RxBluetoothKit/tree/5.0.0/Source/Descriptor.swift#L8-L64">Show on GitHub</a>
262+
<a href="https://github.com/Polidea/RxBluetoothKit/tree/5.0.1/Source/Descriptor.swift#L8-L64">Show on GitHub</a>
263263
</div>
264264
</section>
265265
</div>
@@ -294,7 +294,7 @@ <h4>Declaration</h4>
294294
</div>
295295
</div>
296296
<div class="slightly-smaller">
297-
<a href="https://github.com/Polidea/RxBluetoothKit/tree/5.0.0/Source/Logging.swift#L6-L95">Show on GitHub</a>
297+
<a href="https://github.com/Polidea/RxBluetoothKit/tree/5.0.1/Source/Logging.swift#L6-L95">Show on GitHub</a>
298298
</div>
299299
</section>
300300
</div>
@@ -330,7 +330,7 @@ <h4>Declaration</h4>
330330
</div>
331331
</div>
332332
<div class="slightly-smaller">
333-
<a href="https://github.com/Polidea/RxBluetoothKit/tree/5.0.0/Source/Peripheral.swift#L9-L558">Show on GitHub</a>
333+
<a href="https://github.com/Polidea/RxBluetoothKit/tree/5.0.1/Source/Peripheral.swift#L10-L665">Show on GitHub</a>
334334
</div>
335335
</section>
336336
</div>
@@ -366,7 +366,7 @@ <h4>Declaration</h4>
366366
</div>
367367
</div>
368368
<div class="slightly-smaller">
369-
<a href="https://github.com/Polidea/RxBluetoothKit/tree/5.0.0/Source/ScannedPeripheral.swift#L6-L22">Show on GitHub</a>
369+
<a href="https://github.com/Polidea/RxBluetoothKit/tree/5.0.1/Source/ScannedPeripheral.swift#L6-L22">Show on GitHub</a>
370370
</div>
371371
</section>
372372
</div>
@@ -401,7 +401,7 @@ <h4>Declaration</h4>
401401
</div>
402402
</div>
403403
<div class="slightly-smaller">
404-
<a href="https://github.com/Polidea/RxBluetoothKit/tree/5.0.0/Source/Service.swift#L7-L62">Show on GitHub</a>
404+
<a href="https://github.com/Polidea/RxBluetoothKit/tree/5.0.1/Source/Service.swift#L7-L62">Show on GitHub</a>
405405
</div>
406406
</section>
407407
</div>
@@ -411,7 +411,7 @@ <h4>Declaration</h4>
411411
</section>
412412
</section>
413413
<section id="footer">
414-
<p>&copy; 2018 <a class="link" href="https://polidea.com" target="_blank" rel="external">Polidea</a>. All rights reserved. (Last updated: 2018-03-14)</p>
414+
<p>&copy; 2018 <a class="link" href="https://polidea.com" target="_blank" rel="external">Polidea</a>. All rights reserved. (Last updated: 2018-04-10)</p>
415415
<p>Generated by <a class="link" href="https://github.com/realm/jazzy" target="_blank" rel="external">jazzy ♪♫ v0.9.1</a>, a <a class="link" href="http://realm.io" target="_blank" rel="external">Realm</a> project.</p>
416416
</section>
417417
</article>

docs/Classes/CentralManager.html

Lines changed: 116 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -171,9 +171,9 @@ <h1>CentralManager</h1>
171171
<li class="item">
172172
<div>
173173
<code>
174-
<a name="/s:14RxBluetoothKit14CentralManagerC07centralE0So09CBCentralE0Cv"></a>
174+
<a name="/s:14RxBluetoothKit14CentralManagerC07centralE0So09CBCentralE0Cvp"></a>
175175
<a name="//apple_ref/swift/Property/centralManager" class="dashAnchor"></a>
176-
<a class="token" href="#/s:14RxBluetoothKit14CentralManagerC07centralE0So09CBCentralE0Cv">centralManager</a>
176+
<a class="token" href="#/s:14RxBluetoothKit14CentralManagerC07centralE0So09CBCentralE0Cvp">centralManager</a>
177177
</code>
178178
</div>
179179
<div class="height-container">
@@ -193,7 +193,7 @@ <h4>Declaration</h4>
193193
</div>
194194
</div>
195195
<div class="slightly-smaller">
196-
<a href="https://github.com/Polidea/RxBluetoothKit/tree/5.0.0/Source/CentralManager.swift#L28">Show on GitHub</a>
196+
<a href="https://github.com/Polidea/RxBluetoothKit/tree/5.0.1/Source/CentralManager.swift#L28">Show on GitHub</a>
197197
</div>
198198
</section>
199199
</div>
@@ -272,7 +272,7 @@ <h4>Parameters</h4>
272272
</table>
273273
</div>
274274
<div class="slightly-smaller">
275-
<a href="https://github.com/Polidea/RxBluetoothKit/tree/5.0.0/Source/CentralManager.swift#L68-L78">Show on GitHub</a>
275+
<a href="https://github.com/Polidea/RxBluetoothKit/tree/5.0.1/Source/CentralManager.swift#L68-L78">Show on GitHub</a>
276276
</div>
277277
</section>
278278
</div>
@@ -304,7 +304,7 @@ <h4>Declaration</h4>
304304
</div>
305305
</div>
306306
<div class="slightly-smaller">
307-
<a href="https://github.com/Polidea/RxBluetoothKit/tree/5.0.0/Source/CentralManager.swift#L83-L85">Show on GitHub</a>
307+
<a href="https://github.com/Polidea/RxBluetoothKit/tree/5.0.1/Source/CentralManager.swift#L83-L85">Show on GitHub</a>
308308
</div>
309309
</section>
310310
</div>
@@ -323,9 +323,9 @@ <h3 class="section-name">State</h3>
323323
<li class="item">
324324
<div>
325325
<code>
326-
<a name="/s:14RxBluetoothKit14CentralManagerC5stateAA0B5StateOv"></a>
326+
<a name="/s:14RxBluetoothKit14CentralManagerC5stateAA0B5StateOvp"></a>
327327
<a name="//apple_ref/swift/Property/state" class="dashAnchor"></a>
328-
<a class="token" href="#/s:14RxBluetoothKit14CentralManagerC5stateAA0B5StateOv">state</a>
328+
<a class="token" href="#/s:14RxBluetoothKit14CentralManagerC5stateAA0B5StateOvp">state</a>
329329
</code>
330330
</div>
331331
<div class="height-container">
@@ -345,7 +345,7 @@ <h4>Declaration</h4>
345345
</div>
346346
</div>
347347
<div class="slightly-smaller">
348-
<a href="https://github.com/Polidea/RxBluetoothKit/tree/5.0.0/Source/CentralManager.swift#L90-L92">Show on GitHub</a>
348+
<a href="https://github.com/Polidea/RxBluetoothKit/tree/5.0.1/Source/CentralManager.swift#L90-L92">Show on GitHub</a>
349349
</div>
350350
</section>
351351
</div>
@@ -381,7 +381,7 @@ <h4>Return Value</h4>
381381
<p>Observable that emits <code>next</code> event whenever state changes.</p>
382382
</div>
383383
<div class="slightly-smaller">
384-
<a href="https://github.com/Polidea/RxBluetoothKit/tree/5.0.0/Source/CentralManager.swift#L98-L100">Show on GitHub</a>
384+
<a href="https://github.com/Polidea/RxBluetoothKit/tree/5.0.1/Source/CentralManager.swift#L98-L100">Show on GitHub</a>
385385
</div>
386386
</section>
387387
</div>
@@ -479,7 +479,7 @@ <h4>Return Value</h4>
479479
<p>Infinite stream of scanned peripherals.</p>
480480
</div>
481481
<div class="slightly-smaller">
482-
<a href="https://github.com/Polidea/RxBluetoothKit/tree/5.0.0/Source/CentralManager.swift#L127-L168">Show on GitHub</a>
482+
<a href="https://github.com/Polidea/RxBluetoothKit/tree/5.0.1/Source/CentralManager.swift#L127-L168">Show on GitHub</a>
483483
</div>
484484
</section>
485485
</div>
@@ -561,7 +561,7 @@ <h4>Return Value</h4>
561561
<p><code>Observable</code> which emits next event after connection is established.</p>
562562
</div>
563563
<div class="slightly-smaller">
564-
<a href="https://github.com/Polidea/RxBluetoothKit/tree/5.0.0/Source/CentralManager.swift#L182-L185">Show on GitHub</a>
564+
<a href="https://github.com/Polidea/RxBluetoothKit/tree/5.0.1/Source/CentralManager.swift#L182-L185">Show on GitHub</a>
565565
</div>
566566
</section>
567567
</div>
@@ -627,7 +627,7 @@ <h4>Return Value</h4>
627627
<code><a href="../Classes/Service.html">Service</a></code>s with UUIDs specified in the <code>serviceUUIDs</code> parameter.</p>
628628
</div>
629629
<div class="slightly-smaller">
630-
<a href="https://github.com/Polidea/RxBluetoothKit/tree/5.0.0/Source/CentralManager.swift#L195-L198">Show on GitHub</a>
630+
<a href="https://github.com/Polidea/RxBluetoothKit/tree/5.0.1/Source/CentralManager.swift#L195-L198">Show on GitHub</a>
631631
</div>
632632
</section>
633633
</div>
@@ -680,7 +680,7 @@ <h4>Return Value</h4>
680680
<p>Retrieved <code><a href="../Classes/Peripheral.html">Peripheral</a></code>s.</p>
681681
</div>
682682
<div class="slightly-smaller">
683-
<a href="https://github.com/Polidea/RxBluetoothKit/tree/5.0.0/Source/CentralManager.swift#L204-L207">Show on GitHub</a>
683+
<a href="https://github.com/Polidea/RxBluetoothKit/tree/5.0.1/Source/CentralManager.swift#L204-L207">Show on GitHub</a>
684684
</div>
685685
</section>
686686
</div>
@@ -746,7 +746,7 @@ <h4>Return Value</h4>
746746
<p>Observable which emits next events when <code>peripheral</code> was connected.</p>
747747
</div>
748748
<div class="slightly-smaller">
749-
<a href="https://github.com/Polidea/RxBluetoothKit/tree/5.0.0/Source/CentralManager.swift#L216-L224">Show on GitHub</a>
749+
<a href="https://github.com/Polidea/RxBluetoothKit/tree/5.0.1/Source/CentralManager.swift#L216-L224">Show on GitHub</a>
750750
</div>
751751
</section>
752752
</div>
@@ -800,10 +800,109 @@ <h4>Parameters</h4>
800800
<h4>Return Value</h4>
801801
<p>Observable which emits next events when <code><a href="../Classes/Peripheral.html">Peripheral</a></code> instance was disconnected.
802802
It provides optional error which may contain more information about the cause of the disconnection
803-
if it wasn&rsquo;t the <code>cancelConnection</code> call.</p>
803+
if it wasn&rsquo;t the <code>cancelPeripheralConnection</code> call.</p>
804804
</div>
805805
<div class="slightly-smaller">
806-
<a href="https://github.com/Polidea/RxBluetoothKit/tree/5.0.0/Source/CentralManager.swift#L233-L249">Show on GitHub</a>
806+
<a href="https://github.com/Polidea/RxBluetoothKit/tree/5.0.1/Source/CentralManager.swift#L233-L249">Show on GitHub</a>
807+
</div>
808+
</section>
809+
</div>
810+
</li>
811+
</ul>
812+
</div>
813+
<div class="task-group">
814+
<div class="task-name-container">
815+
<a name="/State%20restoration"></a>
816+
<a name="//apple_ref/swift/Section/State restoration" class="dashAnchor"></a>
817+
<a href="#/State%20restoration">
818+
<h3 class="section-name">State restoration</h3>
819+
</a>
820+
</div>
821+
<ul>
822+
<li class="item">
823+
<div>
824+
<code>
825+
<a name="/s:14RxBluetoothKit14CentralManagerCACSo13DispatchQueueC5queue_s10DictionaryVySSyXlGSg7optionsyAA13RestoredStateVcSg013onWillRestoreL0tcfc"></a>
826+
<a name="//apple_ref/swift/Method/init(queue:options:onWillRestoreState:)" class="dashAnchor"></a>
827+
<a class="token" href="#/s:14RxBluetoothKit14CentralManagerCACSo13DispatchQueueC5queue_s10DictionaryVySSyXlGSg7optionsyAA13RestoredStateVcSg013onWillRestoreL0tcfc">init(queue:options:onWillRestoreState:)</a>
828+
</code>
829+
</div>
830+
<div class="height-container">
831+
<div class="pointer-container"></div>
832+
<section class="section">
833+
<div class="pointer"></div>
834+
<div class="abstract">
835+
<p>Creates new <code>CentralManager</code> instance, which supports bluetooth state restoration.</p>
836+
<div class="aside aside-warning">
837+
<p class="aside-title">Warning</p>
838+
If you pass background queue to the method make sure to observe results on main thread
839+
for UI related code.
840+
841+
</div>
842+
<div class="aside aside-seealso">
843+
<p class="aside-title">Seealso</p>
844+
<p><code><a href="../Structs/RestoredState.html">RestoredState</a></code></p>
845+
846+
</div>
847+
848+
</div>
849+
<div class="declaration">
850+
<h4>Declaration</h4>
851+
<div class="language">
852+
<p class="aside-title">Swift</p>
853+
<pre class="highlight swift"><code><span class="kd">public</span> <span class="n">convenience</span> <span class="nf">init</span><span class="p">(</span><span class="nv">queue</span><span class="p">:</span> <span class="kt">DispatchQueue</span> <span class="o">=</span> <span class="o">.</span><span class="n">main</span><span class="p">,</span>
854+
<span class="nv">options</span><span class="p">:</span> <span class="p">[</span><span class="kt">String</span><span class="p">:</span> <span class="kt">AnyObject</span><span class="p">]?</span> <span class="o">=</span> <span class="kc">nil</span><span class="p">,</span>
855+
<span class="nv">onWillRestoreState</span><span class="p">:</span> <span class="kt"><a href="../Typealiases.html#/s:14RxBluetoothKit18OnWillRestoreStatea">OnWillRestoreState</a></span><span class="p">?</span> <span class="o">=</span> <span class="kc">nil</span><span class="p">)</span></code></pre>
856+
857+
</div>
858+
</div>
859+
<div>
860+
<h4>Parameters</h4>
861+
<table class="graybox">
862+
<tbody>
863+
<tr>
864+
<td>
865+
<code>
866+
<em>queue</em>
867+
</code>
868+
</td>
869+
<td>
870+
<div>
871+
<p>Queue on which bluetooth callbacks are received. By default main thread is used
872+
and all operations and events are executed and received on main thread.</p>
873+
</div>
874+
</td>
875+
</tr>
876+
<tr>
877+
<td>
878+
<code>
879+
<em>options</em>
880+
</code>
881+
</td>
882+
<td>
883+
<div>
884+
<p>An optional dictionary containing initialization options for a central manager.
885+
For more info about it please refer to <a href="https://developer.apple.com/library/ios/documentation/CoreBluetooth/Reference/CBCentralManager_Class/index.html">Central Manager initialization options</a></p>
886+
</div>
887+
</td>
888+
</tr>
889+
<tr>
890+
<td>
891+
<code>
892+
<em>onWillRestoreState</em>
893+
</code>
894+
</td>
895+
<td>
896+
<div>
897+
<p>Closure called when state has been restored.</p>
898+
</div>
899+
</td>
900+
</tr>
901+
</tbody>
902+
</table>
903+
</div>
904+
<div class="slightly-smaller">
905+
<a href="https://github.com/Polidea/RxBluetoothKit/tree/5.0.1/Source/CentralManager+RestoredState.swift#L24-L31">Show on GitHub</a>
807906
</div>
808907
</section>
809908
</div>
@@ -813,7 +912,7 @@ <h4>Return Value</h4>
813912
</section>
814913
</section>
815914
<section id="footer">
816-
<p>&copy; 2018 <a class="link" href="https://polidea.com" target="_blank" rel="external">Polidea</a>. All rights reserved. (Last updated: 2018-03-14)</p>
915+
<p>&copy; 2018 <a class="link" href="https://polidea.com" target="_blank" rel="external">Polidea</a>. All rights reserved. (Last updated: 2018-04-10)</p>
817916
<p>Generated by <a class="link" href="https://github.com/realm/jazzy" target="_blank" rel="external">jazzy ♪♫ v0.9.1</a>, a <a class="link" href="http://realm.io" target="_blank" rel="external">Realm</a> project.</p>
818917
</section>
819918
</article>

0 commit comments

Comments
 (0)