0% found this document useful (1 vote)
492 views20 pages

Firebase CRUD

This document summarizes a presentation about using Firebase for mobile app development. Firebase provides features for authentication, real-time databases, storage, and more. It also recently added analytics, notifications and crash reporting. The presentation demonstrates how to set up a Firebase project, connect an Android app, perform basic CRUD operations on data, and query the database. It also outlines some advanced topics that will be covered in future sessions such as authentication, authorization, validation, storing images, and notifications.

Uploaded by

Aldo Kelvianto
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (1 vote)
492 views20 pages

Firebase CRUD

This document summarizes a presentation about using Firebase for mobile app development. Firebase provides features for authentication, real-time databases, storage, and more. It also recently added analytics, notifications and crash reporting. The presentation demonstrates how to set up a Firebase project, connect an Android app, perform basic CRUD operations on data, and query the database. It also outlines some advanced topics that will be covered in future sessions such as authentication, authorization, validation, storing images, and notifications.

Uploaded by

Aldo Kelvianto
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 20

15 Menit Bersama

(New) Firebase
Aldo Kelvianto / [email protected]

Skenario

Create New App

Fetch data like a pro

Add Loaders, RecyclerView, SQLiteDatabase

Everything works well

Everybody happy

Skenario

Bagaimana dengan manajemen User?

Kemana data ini saya kirim?

Database? MySQL? Postgres?

Hosting dimana?

Push Notification?

Bagaimana menganalisa user?

Solusi

Hire a backend developer

Create your own Web Service

Quit your job?

Use Firebase!

Video

18 Mei 2016, Google I/O.. Coincidence?

firebase.google.com

console.firebase.google.com

Fitur-fitur

Authentication

Real Time Database

Storage

Instant Web Service!

https://firebase.google.com/features/

Fitur-fitur Baru

Analytics, Notifications, Crash Reporting

https://firebase.googleblog.com/

Firebase Setup

Create New App di console

Masukan nama aplikasi

Masukan SHA-1 Android

Download google.json dan pindahkan ke folder


Android

Android Setup

Dependencies on root build.gradle

Dependencies on app build.gradle

apply plugin

Add extra library

https://firebase.google.com/docs/android/setup

Demo Hari Ini

Dinosaurs CRUD

http://intip.in/iakfirebase

Semuanya adalah
Reference

FirebaseDatabase

DatabaseReference

Konfigurasi ada di google-services.json


FirebaseDatabase database = FirebaseDatabase.getInstance();
DatabaseReference myRef = database.getReference("message");

Post Data

setValue

push

updateChildren

Get Data

ValueEventListener (addValueEventListener)
(addListenerForSingleValueEvent)

ChildEventListener (addChildEventListener)

DetachListener

DataSnapshot

Snapshot (Kamera). Kondisi data saat ini.

Java Object. Bisa null, String, Boolean, Long,


Double, Map (Key Value Pairs), List <Object>.
Bukan primitive (Auto-Boxing)

Query

limitToFirst

limitToLast

startAt

endAt

equalTo

Next Time

Token Based Authentication

Authorization pada Security Rules

Validation pada Security Rules

Storing Images

Notification

Q&A

You might also like