25
25
#endif // FIREBASE_JSONBUFFER_SIZE
26
26
27
27
/* *
28
- *Gateway class for Arduino clients to interact withthe Firebase backend .
28
+ *Main class for Arduino clients to interact with Firebase.
29
29
* This implementation is designed to follow Arduino best practices and favor
30
30
* simplicity over all else.
31
31
* For more complicated usecases and more control see the Firebase class in
34
34
class FirebaseArduino {
35
35
public:
36
36
/* *
37
- * Must be called first. This sets the class up for use.
38
- * \param host Your firebase db domain name, usually X.firebaseIO.com.
39
- * \param auth Optional authentication for the db, a secret or token.
37
+ * Must be called first. This initialize the client with the given
38
+ * firebase host and credentials.
39
+ * \param host Your firebase db host, usually X.firebaseio.com.
40
+ * \param auth Optional credentials for the db, a secret or token.
40
41
*/
41
42
void begin (const char * host,const char * auth =" " );
42
43
43
44
/* *
44
- *Adds the datain value to the list located at path.Equivilent to the
45
- * REST API's POST.
45
+ *Writes datato a new child location under the parent at path.
46
+ *Equivalent to the REST API's POST.
46
47
* You should check success() after calling.
47
- * \param path The path inside of your db to thelist you wish to update .
48
- * \param value Data that you wish to addto thelist .
49
- * \return The childname where the data was written.
48
+ * \param path The path inside of your db to theparent object .
49
+ * \param value Data that you wish to addunder theparent .
50
+ * \return Theunique childkey where the data was written.
50
51
*/
51
52
Stringpush (const String& path,const JsonVariant& value);
52
53
53
54
/* *
54
- * Writes the data in value to the node located at pathEquivilent to the
55
+ * Writes the data in value to the node located at pathequivalent to the
55
56
* REST API's PUT.
56
57
* You should check success() after calling.
57
58
* \param path The path inside of your db to the node you wish to update.
@@ -63,16 +64,16 @@ class FirebaseArduino {
63
64
/* *
64
65
* Gets the value located at path.
65
66
* You should check success() after calling.
66
- * \param path The pathinside of your db of the node you wish to retrieve.
67
+ * \param path The pathto the node you wish to retrieve.
67
68
* \return The data located at that path. This may either be a single element
68
69
* or it may be a json structure. Will only be populated if success() is true.
69
70
*/
70
71
FirebaseObjectget (const char * path);
71
72
72
73
/* *
73
- * Remove thevariable , and possibly entire tree, located at path.
74
+ * Remove thenode , and possibly entire tree, located at path.
74
75
* You should check success() after calling.
75
- * \param path The pathinside of your db to the node you wish to remove,
76
+ * \param path The path to the node you wish to remove,
76
77
* including all of its children.
77
78
*/
78
79
void remove (const char * path);