motion-firebase 3.1.6 → 3.1.8

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: ad48aa1a6d29f907d2eba40e0ae2ef2e962fe402
4
- data.tar.gz: 4d70ae0ac685cb45c848a752e21c1c338f746b54
3
+ metadata.gz: 6503d5363ea7180e4da30068867a728b0102e2c0
4
+ data.tar.gz: 623d65d158914138c6222fc314cdbf8bf5c8d729
5
5
  SHA512:
6
- metadata.gz: 1b26db823daea7e84e4e0d01506e4afc7e8bf4905c65e75f9a1e4ddd6164bc6cd4386226779731d1e2e5525c558b4a49d366bfadba6b18d437ec646c309d8954
7
- data.tar.gz: 6d3c80897fa9b8278bf28485828455b4105253e024dfcf273bb0fa008ab76c60689b52a34f74ff4ac3e046d82d4fc40500d45caec3e0f9fee7b94d64d0cf03c8
6
+ metadata.gz: 51bea9bed0381ff25f5456545f233d28ebce0abcee1d8599013d806ea17d857e18fc495d141ea122193a824568a46eebb1580fd7613dfb36abe773649a73fecf
7
+ data.tar.gz: 985283b3ad92a0693c89175946659b4215bdd272a2f1fb8b1ef141ae50e8d4d009ce58ea30f6e150990fb2a1aa721a05cd76485e42c83dbdba40bfc3e74831e5
@@ -7,16 +7,18 @@ class Firebase
7
7
 
8
8
  def open_facebook_session(options={}, &block)
9
9
  ref = self
10
- permissions = options[:permissions] || ['public_profile']
11
- allow_ui = options.fetch(:allow_login_ui, true)
12
- FBSession.openActiveSessionWithReadPermissions(permissions, allowLoginUI: allow_ui,
13
- completionHandler: -> (session, state, error) do
14
- if error
15
- block.call(error, nil)
16
- elsif state == FBSessionStateOpen
17
- token = session.accessTokenData.accessToken
10
+ permissions = options[:permissions] || ['email']
11
+ fb_login = FBSDKLoginManager.alloc.init
12
+ fb_login.logInWithReadPermissions(permissions,
13
+ handler: -> (facebookResult, facebookError) do
14
+ if facebookError
15
+ block.call(facebookError, nil)
16
+ elsif facebookResult.isCancelled
17
+ block.call("Facebook login got cancelled.", nil)
18
+ else
19
+ access_token = FBSDKAccessToken.currentAccessToken.tokenString
18
20
 
19
- ref.authWithOAuthProvider('facebook', token:token, withCompletionBlock:block)
21
+ ref.authWithOAuthProvider('facebook', token: access_token, withCompletionBlock:block)
20
22
  end
21
23
  end)
22
24
  nil
@@ -1,6 +1,6 @@
1
1
  module Motion
2
2
  module Firebase
3
- Version = '3.1.6' # motion-firebase gem version
4
- SdkVersion = '2.2.1' # firebase framework version
3
+ Version = '3.1.8' # motion-firebase gem version
4
+ SdkVersion = '2.4.1' # firebase framework version
5
5
  end
6
6
  end
@@ -0,0 +1,69 @@
1
+ /*
2
+ * Firebase iOS Client Library
3
+ *
4
+ * Copyright © 2015 Firebase - All Rights Reserved
5
+ * https://www.firebase.com
6
+ *
7
+ * Redistribution and use in source and binary forms, with or without
8
+ * modification, are permitted provided that the following conditions are met:
9
+ *
10
+ * 1. Redistributions of source code must retain the above copyright notice, this
11
+ * list of conditions and the following disclaimer.
12
+ *
13
+ * 2. Redistributions in binaryform must reproduce the above copyright notice,
14
+ * this list of conditions and the following disclaimer in the documentation
15
+ * and/or other materials provided with the distribution.
16
+ *
17
+ * THIS SOFTWARE IS PROVIDED BY FIREBASE AS IS AND ANY EXPRESS OR
18
+ * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
19
+ * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO
20
+ * EVENT SHALL FIREBASE BE LIABLE FOR ANY DIRECT,
21
+ * INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
22
+ * BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
23
+ * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF
24
+ * LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
25
+ * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
26
+ * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
27
+ */
28
+
29
+ #import <Foundation/Foundation.h>
30
+
31
+ /**
32
+ * Configuration object for Firebase. You can get the default FConfig object via
33
+ * `[Firebase defaultConfig]` and modify it. You must make all changes to it before
34
+ * you create your first Firebase instance.
35
+ */
36
+ @interface FConfig : NSObject
37
+
38
+ /**
39
+ * By default the Firebase client will keep data in memory while your application is running, but not
40
+ * when it is restarted. By setting this value to YES, the data will be persisted to on-device (disk)
41
+ * storage and will thus be available again when the app is restarted (even when there is no network
42
+ * connectivity at that time). Note that this property must be set before creating your first Firebase
43
+ * reference and only needs to be called once per application.
44
+ *
45
+ * If your app uses Firebase Authentication, the client will automatically persist the user's authentication
46
+ * token across restarts, even without persistence enabled. But if the auth token expired while offline and
47
+ * you've enabled persistence, the client will pause write operations until you successfully re-authenticate
48
+ * (or explicitly unauthenticate) to prevent your writes from being sent unauthenticated and failing due to
49
+ * security rules.
50
+ */
51
+ @property (nonatomic) BOOL persistenceEnabled;
52
+
53
+ /**
54
+ * By default Firebase will use up to 10MB of disk space to cache data. If the cache grows beyond this size,
55
+ * Firebase will start removing data that hasn't been recently used. If you find that your application caches too
56
+ * little or too much data, call this method to change the cache size. This property must be set before creating
57
+ * your first Firebase reference and only needs to be called once per application.
58
+ *
59
+ * Note that the specified cache size is only an approximation and the size on disk may temporarily exceed it
60
+ * at times.
61
+ */
62
+ @property (nonatomic) NSUInteger persistenceCacheSizeBytes;
63
+
64
+ /**
65
+ * Sets the dispatch queue on which all events are raised. The default queue is the main queue.
66
+ */
67
+ @property (nonatomic, strong) dispatch_queue_t callbackQueue;
68
+
69
+ @end
@@ -125,7 +125,7 @@
125
125
 
126
126
 
127
127
  /**
128
- * The name of the location that generated this FDataSnapshot.
128
+ * The key of the location that generated this FDataSnapshot.
129
129
  *
130
130
  * @return An NSString containing the key for the location of this FDataSnapshot.
131
131
  */
@@ -89,6 +89,7 @@
89
89
 
90
90
  /**
91
91
  * To modify the data contained by this instance of FMutableData, set this to any of the native types support by Firebase:
92
+ *
92
93
  * * NSNumber (includes BOOL)
93
94
  * * NSDictionary
94
95
  * * NSArray
@@ -104,6 +105,7 @@
104
105
 
105
106
  /**
106
107
  * Set this property to update the priority of the data at this location. Can be set to the following types:
108
+ *
107
109
  * * NSNumber
108
110
  * * NSString
109
111
  * * nil / NSNull to remove the priority
@@ -44,16 +44,14 @@ typedef NSUInteger FirebaseHandle;
44
44
 
45
45
  /** @name Attaching observers to read data */
46
46
 
47
-
48
47
  /**
49
48
  * observeEventType:withBlock: is used to listen for data changes at a particular location.
50
49
  * This is the primary way to read data from Firebase. Your block will be triggered
51
50
  * for the initial data and again whenever the data changes.
52
51
  *
53
52
  * Use removeObserverWithHandle: to stop receiving updates.
54
- *
55
53
  * @param eventType The type of event to listen for.
56
- * @param block The block that should be called with initial data and updates.
54
+ * @param block The block that should be called with initial data and updates. It is passed the data as an FDataSnapshot.
57
55
  * @return A handle used to unregister this block later using removeObserverWithHandle:
58
56
  */
59
57
  - (FirebaseHandle) observeEventType:(FEventType)eventType withBlock:(void (^)(FDataSnapshot* snapshot))block;
@@ -68,7 +66,8 @@ typedef NSUInteger FirebaseHandle;
68
66
  * Use removeObserverWithHandle: to stop receiving updates.
69
67
  *
70
68
  * @param eventType The type of event to listen for.
71
- * @param block The block that should be called with initial data and updates, as well as the previous child's key.
69
+ * @param block The block that should be called with initial data and updates. It is passed the data as an FDataSnapshot
70
+ * and the previous child's key.
72
71
  * @return A handle used to unregister this block later using removeObserverWithHandle:
73
72
  */
74
73
  - (FirebaseHandle) observeEventType:(FEventType)eventType andPreviousSiblingKeyWithBlock:(void (^)(FDataSnapshot* snapshot, NSString* prevKey))block;
@@ -84,7 +83,7 @@ typedef NSUInteger FirebaseHandle;
84
83
  * Use removeObserverWithHandle: to stop receiving updates.
85
84
  *
86
85
  * @param eventType The type of event to listen for.
87
- * @param block The block that should be called with initial data and updates.
86
+ * @param block The block that should be called with initial data and updates. It is passed the data as an FDataSnapshot.
88
87
  * @param cancelBlock The block that should be called if this client no longer has permission to receive these events
89
88
  * @return A handle used to unregister this block later using removeObserverWithHandle:
90
89
  */
@@ -102,7 +101,8 @@ typedef NSUInteger FirebaseHandle;
102
101
  * Use removeObserverWithHandle: to stop receiving updates.
103
102
  *
104
103
  * @param eventType The type of event to listen for.
105
- * @param block The block that should be called with initial data and updates, as well as the previous child's key.
104
+ * @param block The block that should be called with initial data and updates. It is passed the data as an FDataSnapshot
105
+ * and the previous child's key.
106
106
  * @param cancelBlock The block that should be called if this client no longer has permission to receive these events
107
107
  * @return A handle used to unregister this block later using removeObserverWithHandle:
108
108
  */
@@ -113,7 +113,7 @@ typedef NSUInteger FirebaseHandle;
113
113
  * This is equivalent to observeEventType:withBlock:, except the block is immediately canceled after the initial data is returned.
114
114
  *
115
115
  * @param eventType The type of event to listen for.
116
- * @param block The block that should be called with initial data and updates.
116
+ * @param block The block that should be called. It is passed the data as an FDataSnapshot.
117
117
  */
118
118
  - (void) observeSingleEventOfType:(FEventType)eventType withBlock:(void (^)(FDataSnapshot* snapshot))block;
119
119
 
@@ -123,7 +123,7 @@ typedef NSUInteger FirebaseHandle;
123
123
  * FEventTypeChildChanged events, your block will be passed the key of the previous node by priority order.
124
124
  *
125
125
  * @param eventType The type of event to listen for.
126
- * @param block The block that should be called with initial data and updates.
126
+ * @param block The block that should be called. It is passed the data as an FDataSnapshot and the previous child's key.
127
127
  */
128
128
  - (void) observeSingleEventOfType:(FEventType)eventType andPreviousSiblingKeyWithBlock:(void (^)(FDataSnapshot* snapshot, NSString* prevKey))block;
129
129
 
@@ -134,7 +134,7 @@ typedef NSUInteger FirebaseHandle;
134
134
  * The cancelBlock will be called if you do not have permission to read data at this location.
135
135
  *
136
136
  * @param eventType The type of event to listen for.
137
- * @param block The block that should be called with initial data and updates.
137
+ * @param block The block that should be called. It is passed the data as an FDataSnapshot.
138
138
  * @param cancelBlock The block that will be called if you don't have permission to access this data
139
139
  */
140
140
  - (void) observeSingleEventOfType:(FEventType)eventType withBlock:(void (^)(FDataSnapshot* snapshot))block withCancelBlock:(void (^)(NSError* error))cancelBlock;
@@ -147,7 +147,7 @@ typedef NSUInteger FirebaseHandle;
147
147
  * The cancelBlock will be called if you do not have permission to read data at this location.
148
148
  *
149
149
  * @param eventType The type of event to listen for.
150
- * @param block The block that should be called with initial data and updates.
150
+ * @param block The block that should be called. It is passed the data as an FDataSnapshot and the previous child's key.
151
151
  * @param cancelBlock The block that will be called if you don't have permission to access this data
152
152
  */
153
153
  - (void) observeSingleEventOfType:(FEventType)eventType andPreviousSiblingKeyWithBlock:(void (^)(FDataSnapshot* snapshot, NSString* prevKey))block withCancelBlock:(void (^)(NSError* error))cancelBlock;
@@ -167,6 +167,15 @@ typedef NSUInteger FirebaseHandle;
167
167
  */
168
168
  - (void) removeAllObservers;
169
169
 
170
+ /**
171
+ * By calling `keepSynced:YES` on a location, the data for that location will automatically be downloaded and
172
+ * kept in sync, even when no listeners are attached for that location. Additionally, while a location is kept
173
+ * synced, it will not be evicted from the persistent disk cache.
174
+ *
175
+ * @param keepSynced Pass YES to keep this location synchronized, pass NO to stop synchronization.
176
+ */
177
+ - (void) keepSynced:(BOOL)keepSynced;
178
+
170
179
 
171
180
  /** @name Querying and limiting */
172
181
 
@@ -394,9 +403,9 @@ typedef NSUInteger FirebaseHandle;
394
403
 
395
404
 
396
405
  /**
397
- * Get a Firebase reference for the location that this data came from
406
+ * Get a Firebase reference for the location of this query.
398
407
  *
399
- * @return A Firebase instance for the location of this data
408
+ * @return A Firebase instance for the location of this query.
400
409
  */
401
410
  @property (nonatomic, readonly, strong) Firebase* ref;
402
411
 
@@ -29,12 +29,14 @@
29
29
 
30
30
  #import <Foundation/Foundation.h>
31
31
  #import "FQuery.h"
32
+ #import "FirebaseApp.h"
32
33
  #import "FDataSnapshot.h"
33
34
  #import "FMutableData.h"
34
35
  #import "FTransactionResult.h"
35
36
  #import "FAuthData.h"
36
37
  #import "FAuthType.h"
37
38
  #import "FirebaseServerValue.h"
39
+ #import "FConfig.h"
38
40
 
39
41
  /**
40
42
  * A Firebase reference represents a particular location in your Firebase
@@ -207,7 +209,7 @@ that will automatically be populated by the Firebase Server.
207
209
  - (void) setPriority:(id)priority withCompletionBlock:(void (^)(NSError* error, Firebase* ref))block;
208
210
 
209
211
  /**
210
- * Update changes the values of the keys specified in the dictionary without overwriting other
212
+ * Update changes the values at the specified paths in the dictionary without overwriting other
211
213
  * keys at this location.
212
214
  *
213
215
  * @param values A dictionary of the keys to change and their new values
@@ -226,27 +228,16 @@ that will automatically be populated by the Firebase Server.
226
228
 
227
229
  /** @name Attaching observers to read data */
228
230
 
229
- /*! observeEventType:withBlock: is used to listen for data changes at a particular location.
230
-
231
- This is the primary way to read data from Firebase. Your block will be triggered
232
- for the initial data and again whenever the data changes.
233
-
234
- Use removeObserverWithHandle: to stop receiving updates.
235
-
236
- Supported events types for all realtime observers are specified in FEventType as:
237
-
238
- typedef NS_ENUM(NSInteger, FEventType) {
239
- FEventTypeChildAdded, // 0, fired when a new child node is added to a location
240
- FEventTypeChildRemoved, // 1, fired when a child node is removed from a location
241
- FEventTypeChildChanged, // 2, fired when a child node at a location changes
242
- FEventTypeChildMoved, // 3, fired when a child node moves relative to the other child nodes at a location
243
- FEventTypeValue // 4, fired when any data changes at a location and, recursively, any children
244
- };
245
-
246
- @param eventType The type of event to listen for.
247
- @param block The block that should be called with initial data and updates as a FDataSnapshot.
248
- @return A handle used to unregister this block later using removeObserverWithHandle:
249
- */
231
+ /**
232
+ * observeEventType:withBlock: is used to listen for data changes at a particular location.
233
+ * This is the primary way to read data from Firebase. Your block will be triggered
234
+ * for the initial data and again whenever the data changes.
235
+ *
236
+ * Use removeObserverWithHandle: to stop receiving updates.
237
+ * @param eventType The type of event to listen for.
238
+ * @param block The block that should be called with initial data and updates. It is passed the data as an FDataSnapshot.
239
+ * @return A handle used to unregister this block later using removeObserverWithHandle:
240
+ */
250
241
  - (FirebaseHandle) observeEventType:(FEventType)eventType withBlock:(void (^)(FDataSnapshot* snapshot))block;
251
242
 
252
243
 
@@ -259,8 +250,8 @@ Supported events types for all realtime observers are specified in FEventType as
259
250
  * Use removeObserverWithHandle: to stop receiving updates.
260
251
  *
261
252
  * @param eventType The type of event to listen for.
262
- * @param block The block that should be called with initial data and updates as a FDataSnapshot, as well as the
263
- * previous child's key.
253
+ * @param block The block that should be called with initial data and updates. It is passed the data as an FDataSnapshot
254
+ * and the previous child's key.
264
255
  * @return A handle used to unregister this block later using removeObserverWithHandle:
265
256
  */
266
257
  - (FirebaseHandle) observeEventType:(FEventType)eventType andPreviousSiblingKeyWithBlock:(void (^)(FDataSnapshot* snapshot, NSString* prevKey))block;
@@ -276,7 +267,7 @@ Supported events types for all realtime observers are specified in FEventType as
276
267
  * Use removeObserverWithHandle: to stop receiving updates.
277
268
  *
278
269
  * @param eventType The type of event to listen for.
279
- * @param block The block that should be called with initial data and updates as a FDataSnapshot.
270
+ * @param block The block that should be called with initial data and updates. It is passed the data as an FDataSnapshot.
280
271
  * @param cancelBlock The block that should be called if this client no longer has permission to receive these events
281
272
  * @return A handle used to unregister this block later using removeObserverWithHandle:
282
273
  */
@@ -294,7 +285,8 @@ Supported events types for all realtime observers are specified in FEventType as
294
285
  * Use removeObserverWithHandle: to stop receiving updates.
295
286
  *
296
287
  * @param eventType The type of event to listen for.
297
- * @param block The block that should be called with initial data and updates as a FDataSnapshot, as well as the previous child's key.
288
+ * @param block The block that should be called with initial data and updates. It is passed the data as an FDataSnapshot
289
+ * and the previous child's key.
298
290
  * @param cancelBlock The block that should be called if this client no longer has permission to receive these events
299
291
  * @return A handle used to unregister this block later using removeObserverWithHandle:
300
292
  */
@@ -305,7 +297,7 @@ Supported events types for all realtime observers are specified in FEventType as
305
297
  * This is equivalent to observeEventType:withBlock:, except the block is immediately canceled after the initial data is returned.
306
298
  *
307
299
  * @param eventType The type of event to listen for.
308
- * @param block The block that should be called with initial data and updates as a FDataSnapshot.
300
+ * @param block The block that should be called. It is passed the data as an FDataSnapshot.
309
301
  */
310
302
  - (void) observeSingleEventOfType:(FEventType)eventType withBlock:(void (^)(FDataSnapshot* snapshot))block;
311
303
 
@@ -315,7 +307,7 @@ Supported events types for all realtime observers are specified in FEventType as
315
307
  * FEventTypeChildChanged events, your block will be passed the key of the previous node by priority order.
316
308
  *
317
309
  * @param eventType The type of event to listen for.
318
- * @param block The block that should be called with initial data and updates as a FDataSnapshot, as well as the previous child's key.
310
+ * @param block The block that should be called. It is passed the data as an FDataSnapshot and the previous child's key.
319
311
  */
320
312
  - (void) observeSingleEventOfType:(FEventType)eventType andPreviousSiblingKeyWithBlock:(void (^)(FDataSnapshot* snapshot, NSString* prevKey))block;
321
313
 
@@ -326,7 +318,7 @@ Supported events types for all realtime observers are specified in FEventType as
326
318
  * The cancelBlock will be called if you do not have permission to read data at this location.
327
319
  *
328
320
  * @param eventType The type of event to listen for.
329
- * @param block The block that should be called with initial data and updates as a FDataSnapshot.
321
+ * @param block The block that should be called. It is passed the data as an FDataSnapshot.
330
322
  * @param cancelBlock The block that will be called if you don't have permission to access this data
331
323
  */
332
324
  - (void) observeSingleEventOfType:(FEventType)eventType withBlock:(void (^)(FDataSnapshot* snapshot))block withCancelBlock:(void (^)(NSError* error))cancelBlock;
@@ -339,7 +331,7 @@ Supported events types for all realtime observers are specified in FEventType as
339
331
  * The cancelBlock will be called if you do not have permission to read data at this location.
340
332
  *
341
333
  * @param eventType The type of event to listen for.
342
- * @param block The block that should be called with initial data and updates as a FDataSnapshot, as well as the previous child's key.
334
+ * @param block The block that should be called. It is passed the data as an FDataSnapshot and the previous child's key.
343
335
  * @param cancelBlock The block that will be called if you don't have permission to access this data
344
336
  */
345
337
  - (void) observeSingleEventOfType:(FEventType)eventType andPreviousSiblingKeyWithBlock:(void (^)(FDataSnapshot* snapshot, NSString* prevKey))block withCancelBlock:(void (^)(NSError* error))cancelBlock;
@@ -353,9 +345,19 @@ Supported events types for all realtime observers are specified in FEventType as
353
345
  */
354
346
  - (void) removeObserverWithHandle:(FirebaseHandle)handle;
355
347
 
348
+ /**
349
+ * By calling `keepSynced:YES` on a location, the data for that location will automatically be downloaded and
350
+ * kept in sync, even when no listeners are attached for that location. Additionally, while a location is kept
351
+ * synced, it will not be evicted from the persistent disk cache.
352
+ *
353
+ * @param keepSynced Pass YES to keep this location synchronized, pass NO to stop synchronization.
354
+ */
355
+ - (void) keepSynced:(BOOL)keepSynced;
356
+
356
357
 
357
358
  /**
358
- * Detach all blocks previously attached to this Firebase location with observeEventType:withBlock:
359
+ * Calling removeAllObservers does not remove any observers at child references.
360
+ * removeAllObservers must be called again for each child reference where a listener was established to remove the observers.
359
361
  */
360
362
  - (void) removeAllObservers;
361
363
 
@@ -562,11 +564,11 @@ Supported events types for all realtime observers are specified in FEventType as
562
564
  /**
563
565
  * queryEqualToValue:childKey: is used to generate a reference to a limited view of the data at this location.
564
566
  * The FQuery instance returned by queryEqualToValue:childKey will respond to events at nodes with a value
565
- * equal to the supplied argument with a name equal to childKey. There will be at most one node that matches because
567
+ * equal to the supplied argument with a key equal to childKey. There will be at most one node that matches because
566
568
  * child keys are unique.
567
569
  *
568
570
  * @param value The value that the data returned by this FQuery will have
569
- * @param childKey The name of nodes with the right value
571
+ * @param childKey The key of nodes with the right value
570
572
  * @return An FQuery instance, limited to data with the supplied value and the key.
571
573
  */
572
574
  - (FQuery *) queryEqualToValue:(id)value childKey:(NSString *)childKey;
@@ -1013,19 +1015,41 @@ Supported events types for all realtime observers are specified in FEventType as
1013
1015
  */
1014
1016
  @property (strong, readonly, nonatomic) NSString* key;
1015
1017
 
1018
+ /**
1019
+ * Gets the FirebaseApp instance associated with this reference.
1020
+ *
1021
+ * @return The FirebaseApp object for this reference.
1022
+ */
1023
+ @property (strong, readonly, nonatomic) FirebaseApp *app;
1024
+
1016
1025
 
1017
1026
  /** @name Global configuration and settings */
1018
1027
 
1019
1028
  /** Set the default dispatch queue for event blocks.
1020
- *
1021
- * @param queue The queue to set as the default for running blocks for all Firebase event types.
1029
+ *
1030
+ * @param queue The queue to set as the default for running blocks for all Firebase event types.
1031
+ * @deprecated This method is deprecated
1032
+ * @note Please use [Firebase defaultConfig].callbackQueue instead
1022
1033
  */
1023
- + (void) setDispatchQueue:(dispatch_queue_t)queue;
1034
+ + (void) setDispatchQueue:(dispatch_queue_t)queue __attribute__((deprecated));
1024
1035
 
1025
1036
  /** Retrieve the Firebase SDK version. */
1026
1037
  + (NSString *) sdkVersion;
1027
1038
 
1028
1039
  + (void) setLoggingEnabled:(BOOL)enabled;
1029
1040
 
1030
- + (void) setOption:(NSString*)option to:(id)value;
1041
+ /**
1042
+ * Returns the default config object, used for configuring Firebase client behavior.
1043
+ *
1044
+ * This can be modified until you create your first `Firebase` instance.
1045
+ */
1046
+ + (FConfig *)defaultConfig;
1047
+
1048
+ /**
1049
+ * @deprecated This method is deprecated
1050
+ * @note Please enable persistence by setting [Firebase defaultConfig].persistenceEnabled = YES instead.
1051
+ * @param option Option to set.
1052
+ * @param value Value to set.
1053
+ */
1054
+ + (void) setOption:(NSString*)option to:(id)value __attribute__((deprecated));
1031
1055
  @end
@@ -0,0 +1,34 @@
1
+ #import <Foundation/Foundation.h>
2
+
3
+ /**
4
+ * All Firebase references to the same database share a connection, persistent cache, etc. FirebaseApp
5
+ * represents this shared state and can be accessed from any reference via its `app` property.
6
+ * It has methods for managing your Firebase connection, etc.
7
+ *
8
+ * There is a one-to-one relationship between a FirebaseApp instance and a connection to Firebase.
9
+ */
10
+ @interface FirebaseApp : NSObject
11
+
12
+ /**
13
+ * The Firebase client automatically queues writes and sends them to the server at the earliest opportunity,
14
+ * depending on network connectivity. In some cases (e.g. offline usage) there may be a large number of writes
15
+ * waiting to be sent. Calling this method will purge all outstanding writes so they are abandoned.
16
+ *
17
+ * All writes will be purged, including transactions and {@link Firebase#onDisconnect} writes. The writes will
18
+ * be rolled back locally, perhaps triggering events for affected event listeners, and the client will not
19
+ * (re-)send them to the Firebase backend.
20
+ */
21
+ - (void)purgeOutstandingWrites;
22
+
23
+
24
+ /**
25
+ * Shuts down our connection to the Firebase backend until goOnline is called.
26
+ */
27
+ - (void)goOffline;
28
+
29
+ /**
30
+ * Resumes our connection to the Firebase backend after a previous goOffline call.
31
+ */
32
+ - (void)goOnline;
33
+
34
+ @end
@@ -0,0 +1,6 @@
1
+ framework module Firebase {
2
+ umbrella header "Firebase.h"
3
+
4
+ export *
5
+ module * { export * }
6
+ }
@@ -0,0 +1,47 @@
1
+ Google LevelDB
2
+ Copyright (c) 2011 The LevelDB Authors. All rights reserved.
3
+
4
+ Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met:
5
+
6
+ * Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer.
7
+
8
+ * Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution.
9
+
10
+ * Neither the name of Google Inc. nor the names of its contributors may be used to endorse or promote products derived from this software without specific prior written permission.
11
+
12
+ THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
13
+
14
+ --
15
+
16
+ Square Socket Rocket
17
+ Copyright 2012 Square Inc.
18
+
19
+ 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
20
+
21
+ http://www.apache.org/licenses/LICENSE-2.0
22
+
23
+ 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.
24
+
25
+ --
26
+
27
+ APLevelDB
28
+ Created by Adam Preble on 1/23/12.
29
+ Copyright (c) 2012 Adam Preble. All rights reserved.
30
+
31
+ Permission is hereby granted, free of charge, to any person obtaining a copy
32
+ of this software and associated documentation files (the "Software"), to deal
33
+ in the Software without restriction, including without limitation the rights
34
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
35
+ copies of the Software, and to permit persons to whom the Software is
36
+ furnished to do so, subject to the following conditions:
37
+
38
+ The above copyright notice and this permission notice shall be included in
39
+ all copies or substantial portions of the Software.
40
+
41
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
42
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
43
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
44
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
45
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
46
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
47
+ THE SOFTWARE.
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: motion-firebase
3
3
  version: !ruby/object:Gem::Version
4
- version: 3.1.6
4
+ version: 3.1.8
5
5
  platform: ruby
6
6
  authors:
7
7
  - Colin T.A. Gray
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2015-05-15 00:00:00.000000000 Z
11
+ date: 2015-10-08 00:00:00.000000000 Z
12
12
  dependencies: []
13
13
  description: |
14
14
  Adds more rubyesque methods to the built-in classes.
@@ -18,8 +18,6 @@ executables: []
18
18
  extensions: []
19
19
  extra_rdoc_files: []
20
20
  files:
21
- - README.md
22
- - lib/firebase-auth/firebase_simple_login.rb
23
21
  - lib/firebase/fdata_snapshot.rb
24
22
  - lib/firebase/firebase.rb
25
23
  - lib/firebase/firebase_auth.rb
@@ -28,19 +26,25 @@ files:
28
26
  - lib/firebase/firebase_twitter_helper.rb
29
27
  - lib/firebase/fquery.rb
30
28
  - lib/firebase/version.rb
29
+ - lib/firebase-auth/firebase_simple_login.rb
31
30
  - lib/motion-firebase-auth.rb
32
31
  - lib/motion-firebase.rb
33
32
  - lib/vendor/Firebase.framework/Firebase
34
- - lib/vendor/Firebase.framework/Versions/A/Firebase
35
- - lib/vendor/Firebase.framework/Versions/A/Headers/FAuthData.h
36
- - lib/vendor/Firebase.framework/Versions/A/Headers/FAuthType.h
37
- - lib/vendor/Firebase.framework/Versions/A/Headers/FDataSnapshot.h
38
- - lib/vendor/Firebase.framework/Versions/A/Headers/FEventType.h
39
- - lib/vendor/Firebase.framework/Versions/A/Headers/FMutableData.h
40
- - lib/vendor/Firebase.framework/Versions/A/Headers/FQuery.h
41
- - lib/vendor/Firebase.framework/Versions/A/Headers/FTransactionResult.h
42
- - lib/vendor/Firebase.framework/Versions/A/Headers/Firebase.h
43
- - lib/vendor/Firebase.framework/Versions/A/Headers/FirebaseServerValue.h
33
+ - lib/vendor/Firebase.framework/Headers/FAuthData.h
34
+ - lib/vendor/Firebase.framework/Headers/FAuthType.h
35
+ - lib/vendor/Firebase.framework/Headers/FConfig.h
36
+ - lib/vendor/Firebase.framework/Headers/FDataSnapshot.h
37
+ - lib/vendor/Firebase.framework/Headers/FEventType.h
38
+ - lib/vendor/Firebase.framework/Headers/Firebase.h
39
+ - lib/vendor/Firebase.framework/Headers/FirebaseApp.h
40
+ - lib/vendor/Firebase.framework/Headers/FirebaseServerValue.h
41
+ - lib/vendor/Firebase.framework/Headers/FMutableData.h
42
+ - lib/vendor/Firebase.framework/Headers/FQuery.h
43
+ - lib/vendor/Firebase.framework/Headers/FTransactionResult.h
44
+ - lib/vendor/Firebase.framework/Info.plist
45
+ - lib/vendor/Firebase.framework/Modules/module.modulemap
46
+ - lib/vendor/Firebase.framework/NOTICE
47
+ - README.md
44
48
  homepage: https://github.com/colinta/motion-firebase
45
49
  licenses:
46
50
  - BSD
@@ -61,7 +65,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
61
65
  version: '0'
62
66
  requirements: []
63
67
  rubyforge_project:
64
- rubygems_version: 2.4.5
68
+ rubygems_version: 2.0.14
65
69
  signing_key:
66
70
  specification_version: 4
67
71
  summary: A RubyMotion wrapper for the Firebase iOS SDK