+ All Categories
Home > Technology > Realtime Database with iOS and Firebase

Realtime Database with iOS and Firebase

Date post: 14-Jan-2017
Category:
Upload: nscoder-mexico
View: 52 times
Download: 0 times
Share this document with a friend
33
Transcript

RealtimeDatabase

Authentication

Hosting

console.firebase.google.com

things that matters...

all datait's a JSON tree

NSStringNSNumberNSDictionaryNSArray

Data Types

let rootRef = FIRDatabase.database().reference()

/

CRUD

setValuechildByAutoIdupdateChildValuesrunTransactionBlock

Save Data

let rootRef = FIRDatabase.database().reference()let logRef = rootRef.child("log")let logKey = logRef.childByAutoId().key

let value = "Hello World"logRef.child(logKey).setValue(value)

/log/-KReb10DaQhFoLb7w7Oi: “Hello World”

FIRDataEventType.Value.ChildAdded.ChildChanged.ChildRemoved.ChildMoved

Retrieve Data

let rootRef = FIRDatabase.database().reference()let logRef = rootRef.child("log")

logRef.observeEventType(.Value, withBlock: { (snapshot) in // Funny Stuff print(snapshot) }, withCancelBlock: nil)

ok, let’s make the mostamazing demo...

A TO-DO LIST!

let’s go!

...

lets everyoneto join the fun!

bit.ly/pokefirebase

where to go from here?

firebase.google.com/docsyoutube.com/user/FirebaseLets Build That App

lmgtfy.com

lol

Gabo Lugo.@gabovanlugo

Thanks!


Recommended