SlideShare a Scribd company logo
Android CHATAPP
with FIREBASE
FB.COM/THANHNB1101
THANHNOTES.COM
THANHNB1101@GMAIL.COM
0975.705.669
Nguyen Ba Thanh
u Mobile App/Game Expert
u CoFounder & CEO WePlay
u Products
u TOP 50 BlueBirdAward 2015
u “Bat Chu” – 10M Downloads 2015
u “Lich Van Nien” – 5M Downloads 2015
- Leading the Viet calendar mobile market for now
thanhnotes.com
NGUYEN BA THANH
fb.com/thanhnb1101
thanhnotes.com
thanhnb1101@gmail.com
0975.705.669
Lecture Structure
1. Firebase Introduction
2. Demo ChatApp
3. [Key Notes] Firebase technical for ChatApp
4. [Guide] Step by step to build ChatApp with Firebase
thanhnotes.com
1. 3 key values you will get?
3 key values you will get?
1. Knowledge Firebase basic
2. Know-how to create app on Android Studio
3. Know-how to create Android ChatApp with Firebase for million users
thanhnotes.com
2. Firebase Introduction
u A powerful platform for your mobile or web application
u Build cross-platform native mobile/web apps with Android, iOS, and JavaScript SDKs
thanhnotes.com
2. Firebase Introduction thanhnotes.com
3. Demo ChatApp
u Demo ChatApp
thanhnotes.com
4. [Key Notes] Firebase technical
1. Create an account
2. Install Firebase
3. Add Android permission
4. Setup Firebase on Android
5. Read/Write to Firebase Database
6. Authenticate users
7. Secure data
thanhnotes.com
4. [Key Notes] Firebase technical
1. Create an account
2. Install Firebase
3. Add Android permission
4. Setup Firebase on Android
5. Read/Write to Firebase Database
6. Authenticate users
7. Secure data
thanhnotes.com
Link to registry: https://www.firebase.com/signup/
4. [Key Notes] Firebase technical
1. Create an account
2. Install Firebase
3. Add Android permission
4. Setup Firebase on Android
5. Read/Write to Firebase Database
6. Authenticate users
7. Secure data
thanhnotes.com
Download Firebase SDK: edit build.gradle & rebuild
4. [Key Notes] Firebase technical
1. Create an account
2. Install Firebase
3. Add Android permission
4. Setup Firebase on Android
5. Read/Write to Firebase Database
6. Authenticate users
7. Secure data
thanhnotes.com
Add  permission  INTERNET  to  AndroidManifest.xml
4. [Key Notes] Firebase technical
1. Create an account
2. Install Firebase
3. Add Android permission
4. Setup Firebase on Android
5. Read/Write to Firebase Database
6. Authenticate users
7. Secure data
thanhnotes.com
Add to your activity (in this case, it’s
MainActivity.java)
4. [Key Notes] Firebase technical
1. Create an account
2. Install Firebase
3. Add Android permission
4. Setup Firebase on Android
5. Read/Write to Firebase Database
6. Authenticate users
7. Secure data
thanhnotes.com
5.1. Create a reference to Firebase database
5.2. Write data
5.3. Read data
4. [Key Notes] Firebase technical
1. Create an account
2. Install Firebase
3. Add Android permission
4. Setup Firebase on Android
5. Read/Write to Firebase Database
6. Authenticate users
7. Secure data
thanhnotes.com
1. Choose the Login & Auth tab.
2. Select the Email & Password tab and enable
authentication.
4. [Key Notes] Firebase technical
1. Create an account
2. Install Firebase
3. Add Android permission
4. Setup Firebase on Android
5. Read/Write to Firebase Database
6. Authenticate users
7. Secure data
thanhnotes.com
5. [Guide] Build ChatApp Firebase
Prepare:
Download and extract files to your computer:
http://bit.ly/chatappvtc
thanhnotes.com
5. [Guide] Build ChatApp Firebase
Step 1. Create ChatApp by Anroid Studio
Step 2. Install Firebase
Step 3. Add Android permission
Step 4. Create UI & implement
Step 5. Prepare classes to get data
Step 6. Setup Firebase
Step 7. Connect database
Step 8. Login with Firebase
Step 9. Get messages to listview
Step 10. Send message
thanhnotes.com
5. [Guide] Build ChatApp Firebase
Step 1. Create ChatApp by
Anroid Studio
Step 2. Install Firebase
Step 3. Add Android permission
Step 4. Create UI & implement
Step 5. Prepare classes to get data
Step 6. Setup Firebase
Step 7. Connect database
Step 8. Login with Firebase
Step 9. Get messages to listview
Step 10. Send message
1. Launch  Android  Studio
2.  File  -­>  New  -­>  New  Project
3.  Fill  infomation  of  project  and  finish
4.  Try  to  run  on  simulator  or  real  device  
thanhnotes.com
5. [Guide] Build ChatApp Firebase
Step 1. Create ChatApp by Anroid Studio
Step 2. Install Firebase
Step 3. Add Android permission
Step 4. Create UI & implement
Step 5. Prepare classes to get data
Step 6. Setup Firebase
Step 7. Connect database
Step 8. Login with Firebase
Step 9. Get messages to listview
Step 10. Send message
Add this code to build.gradle (app) and rebuild project to download Firebase SDK
dependencies {
compile 'com.firebase:firebase-client-android:2.5.1+’
}
//You can copy this codes in file step2.txt
thanhnotes.com
5. [Guide] Build ChatApp Firebase
Step 1. Create ChatApp by Anroid Studio
Step 2. Install Firebase
Step 3. Add Android permission
Step 4. Create UI & implement
Step 5. Prepare classes to get data
Step 6. Setup Firebase
Step 7. Connect database
Step 8. Login with Firebase
Step 9. Get messages to listview
Step 10. Send message
Add more this code to AndroidManifests.xml file (code in file step3.txt)
thanhnotes.com
5. [Guide] Build ChatApp Firebase
Step 1. Create ChatApp by Anroid Studio
Step 2. Install Firebase
Step 3. Add Android permission
Step 4. Create UI & implement
Step 5. Prepare classes to get data
Step 6. Setup Firebase
Step 7. Connect database
Step 8. Login with Firebase
Step 9. Get messages to listview
Step 10. Send message
Copy 3 file xml in folder “ShareResource/layout” to your layout
folder of your project and fill code to MainActivity.java as
step4.txt
thanhnotes.com
5. [Guide] Build ChatApp Firebase
Step 1. Create ChatApp by Anroid Studio
Step 2. Install Firebase
Step 3. Add Android permission
Step 4. Create UI & implement
Step 5. Prepare classes to get
data
Step 6. Setup Firebase
Step 7. Connect database
Step 8. Login with Firebase
Step 9. Get messages to listview
Step 10. Send message
Copy 2 classes: FirebaseListAdapter.java and Message.java into
your project (app/java/vtc.edu.vn.vtcchatapp/)
thanhnotes.com
5. [Guide] Build ChatApp Firebase
Step 1. Create ChatApp by Anroid Studio
Step 2. Install Firebase
Step 3. Add Android permission
Step 4. Create UI & implement
Step 5. Prepare classes to get data
Step 6. Setup Firebase
Step 7. Connect database
Step 8. Login with Firebase
Step 9. Get messages to listview
Step 10. Send message
Copy this code to your MainActivity.java
Firebase.setAndroidContext(this);
thanhnotes.com
(refer code in step6.txt)
5. [Guide] Build ChatApp Firebase
Step 1. Create ChatApp by Anroid Studio
Step 2. Install Firebase
Step 3. Add Android permission
Step 4. Create UI & implement
Step 5. Prepare classes to get data
Step 6. Setup Firebase
Step 7. Connect database
Step 8. Login with Firebase
Step 9. Get messages to listview
Step 10. Send message
Step 7.1. Define variables in MainActivity.java
Step 7.2. Add below code to MainActivity.java
thanhnotes.com
5. [Guide] Build ChatApp Firebase
Step 1. Create ChatApp by Anroid Studio
Step 2. Install Firebase
Step 3. Add Android permission
Step 4. Create UI & implement
Step 5. Prepare classes to get data
Step 6. Setup Firebase
Step 7. Connect database
Step 8. Login with Firebase
Step 9. Get messages to listview
Step 10. Send message
Copy code in file step8.txt to mLoginButton.setOnClickListener
thanhnotes.com
5. [Guide] Build ChatApp Firebase
Step 1. Create ChatApp by Anroid Studio
Step 2. Install Firebase
Step 3. Add Android permission
Step 4. Create UI & implement
Step 5. Prepare classes to get data
Step 6. Setup Firebase
Step 7. Connect database
Step 8. Login with Firebase
Step 9. Get messages to listview
Step 10. Send message
Step 9.1. Define variable FirebaseListAdapter
Step 9.2. Get messages to adapter and display to listview
Copy code in step9.txt
thanhnotes.com
5. [Guide] Build ChatApp Firebase
Step 1. Create ChatApp by Anroid Studio
Step 2. Install Firebase
Step 3. Add Android permission
Step 4. Create UI & implement
Step 5. Prepare classes to get data
Step 6. Setup Firebase
Step 7. Connect database
Step 8. Login with Firebase
Step 9. Get messages to listview
Step 10. Send message
Add code in step10.txt to mSend.setOnClickListener
thanhnotes.com
5. [Guide] Build ChatApp Firebase
Step 1. Create ChatApp by Anroid Studio
Step 2. Install Firebase
Step 3. Add Android permission
Step 4. Create UI & implement
Step 5. Prepare classes to get data
Step 6. Setup Firebase
Step 7. Connect database
Step 8. Login with Firebase
Step 9. Get messages to listview
Step 10. Send message
Final: Run
thanhnotes.com
Thanks for listen!
fb.com/thanhnb1101
thanhnotes.com
thanhnb1101@gmail.com
0975.705.669

More Related Content

What's hot (20)

PDF
Mobile Test Automation - Appium
Maria Machlowska
 
PPTX
Mobile Automation with Appium
Manoj Kumar Kumar
 
PDF
Introduction to ASP.NET Core
Avanade Nederland
 
PPTX
API Docs with OpenAPI 3.0
Fabrizio Ferri-Benedetti
 
PPTX
Blog application
AMANKUMARKHANNA
 
PDF
Kong API
Patrick Pierson
 
PDF
Appium: Automation for Mobile Apps
Sauce Labs
 
PPTX
What is Flutter
Malan Amarasinghe
 
PPTX
Top 10 test architect interview questions and answers
tonychoper5506
 
PDF
API for Beginners
Gustavo De Vita
 
PPTX
Appium solution
Nael Abd Eljawad
 
PDF
API Security Best Practices & Guidelines
Prabath Siriwardena
 
PDF
Single page applications
Diego Cardozo
 
PPTX
Smarter deployments with octopus deploy
Thibaud Gravrand
 
PDF
DevOps for beginners
Pradeep Patel, PMP®
 
PPT
Ios development
Shakil Ahmed
 
PPTX
Server Driven UI in iOS
Mohammad Azam
 
PPTX
QA Challenge Accepted 4.0 - Cypress vs. Selenium
Lyudmil Latinov
 
PDF
Introduction To Mobile-Automation
Mindfire Solutions
 
PPTX
Getting Started with React.js
Smile Gupta
 
Mobile Test Automation - Appium
Maria Machlowska
 
Mobile Automation with Appium
Manoj Kumar Kumar
 
Introduction to ASP.NET Core
Avanade Nederland
 
API Docs with OpenAPI 3.0
Fabrizio Ferri-Benedetti
 
Blog application
AMANKUMARKHANNA
 
Kong API
Patrick Pierson
 
Appium: Automation for Mobile Apps
Sauce Labs
 
What is Flutter
Malan Amarasinghe
 
Top 10 test architect interview questions and answers
tonychoper5506
 
API for Beginners
Gustavo De Vita
 
Appium solution
Nael Abd Eljawad
 
API Security Best Practices & Guidelines
Prabath Siriwardena
 
Single page applications
Diego Cardozo
 
Smarter deployments with octopus deploy
Thibaud Gravrand
 
DevOps for beginners
Pradeep Patel, PMP®
 
Ios development
Shakil Ahmed
 
Server Driven UI in iOS
Mohammad Azam
 
QA Challenge Accepted 4.0 - Cypress vs. Selenium
Lyudmil Latinov
 
Introduction To Mobile-Automation
Mindfire Solutions
 
Getting Started with React.js
Smile Gupta
 

Viewers also liked (14)

PPTX
Client server chat application
Piyush Rawat
 
PPTX
Windows chat application
Yogyata Mehtani
 
PPTX
Chat Application
kuldip kumar
 
PPT
Lan chat system
Wipro
 
PDF
Multicast chat with file and desktop sharing
Khagendra Chapre
 
PDF
Report on e-Notice App (An Android Application)
Priyanka Kapoor
 
DOC
Android Report
Ganesh Waghmare
 
PDF
Android report
blogger at indiandswad
 
PDF
Chat Application [Full Documentation]
Rajon
 
PPT
Multi user chat system using java
Akhil Goutham Kotini
 
PPTX
PUBLIC POLICY: AN INTRODUCTION
Tanzania Public Service College
 
PPT
Chat application
Mudasir Sunasara
 
PDF
A project report on chat application
Kumar Gaurav
 
DOC
My Project Report Documentation with Abstract & Snapshots
Usman Sait
 
Client server chat application
Piyush Rawat
 
Windows chat application
Yogyata Mehtani
 
Chat Application
kuldip kumar
 
Lan chat system
Wipro
 
Multicast chat with file and desktop sharing
Khagendra Chapre
 
Report on e-Notice App (An Android Application)
Priyanka Kapoor
 
Android Report
Ganesh Waghmare
 
Android report
blogger at indiandswad
 
Chat Application [Full Documentation]
Rajon
 
Multi user chat system using java
Akhil Goutham Kotini
 
PUBLIC POLICY: AN INTRODUCTION
Tanzania Public Service College
 
Chat application
Mudasir Sunasara
 
A project report on chat application
Kumar Gaurav
 
My Project Report Documentation with Abstract & Snapshots
Usman Sait
 
Ad

Similar to How to build Android Chat App with Firebase for 2 hours? (20)

PDF
React Native Firebase Realtime Database + Authentication
Kobkrit Viriyayudhakorn
 
PDF
Online mobile game server use Firebase realtime aatabase
Nguyễn Bá Thành
 
PDF
Devfest SouthWest, Nigeria - Firebase
Moyinoluwa Adeyemi
 
PDF
Firebase Auth Tutorial
Bukhori Aqid
 
PDF
Part 4 How to use EF Core with MongoDb in Blazor Server Web Application.pdf
Facile Technolab
 
PDF
Firebase Codelab - 2018 Milano
Bret McGowen - NYC Google Developer Advocate
 
PPTX
Chatbot development with Microsoft Bot Framework
Md. Mahedee Hasan
 
PPT
Benefits of the CodeIgniter Framework
Toby Beresford
 
PDF
Build sites on iis
Paul Davis
 
PPTX
Webinar on How to use MyAppConverter
Jaoued Ahmed
 
DOC
Dbs-Week5-Class-Exercises
Digital Insights - Digital Marketing Agency
 
PPTX
Creating and Deploying a Bot Service Using the Bot Framework and Visual Studio
Murray Fife
 
PDF
Firebase Cloud Messaging for iOS
James Daniels
 
PPTX
Firebasics
Patrick Walker
 
PPTX
Firebase, Jetpack, Retrofit.pptx
wasimmullick88
 
PDF
Web Development with Node and Express 2nd Edition Ethan Brown
simsiraraman
 
PPT
Facebook 3rd Party Api
Yoss Cohen
 
PPTX
flask.pptx
asif290119
 
PDF
Complete Download Web Development with Node and Express 2nd Edition Ethan Bro...
eriyahkatoh
 
PPTX
Build your first Chatbot
Nadim GOUIA
 
React Native Firebase Realtime Database + Authentication
Kobkrit Viriyayudhakorn
 
Online mobile game server use Firebase realtime aatabase
Nguyễn Bá Thành
 
Devfest SouthWest, Nigeria - Firebase
Moyinoluwa Adeyemi
 
Firebase Auth Tutorial
Bukhori Aqid
 
Part 4 How to use EF Core with MongoDb in Blazor Server Web Application.pdf
Facile Technolab
 
Firebase Codelab - 2018 Milano
Bret McGowen - NYC Google Developer Advocate
 
Chatbot development with Microsoft Bot Framework
Md. Mahedee Hasan
 
Benefits of the CodeIgniter Framework
Toby Beresford
 
Build sites on iis
Paul Davis
 
Webinar on How to use MyAppConverter
Jaoued Ahmed
 
Creating and Deploying a Bot Service Using the Bot Framework and Visual Studio
Murray Fife
 
Firebase Cloud Messaging for iOS
James Daniels
 
Firebasics
Patrick Walker
 
Firebase, Jetpack, Retrofit.pptx
wasimmullick88
 
Web Development with Node and Express 2nd Edition Ethan Brown
simsiraraman
 
Facebook 3rd Party Api
Yoss Cohen
 
flask.pptx
asif290119
 
Complete Download Web Development with Node and Express 2nd Edition Ethan Bro...
eriyahkatoh
 
Build your first Chatbot
Nadim GOUIA
 
Ad

Recently uploaded (20)

PPTX
Views on Education of Indian Thinkers Mahatma Gandhi.pptx
ShrutiMahanta1
 
PPSX
Health Planning in india - Unit 03 - CHN 2 - GNM 3RD YEAR.ppsx
Priyanshu Anand
 
PDF
Federal dollars withheld by district, charter, grant recipient
Mebane Rash
 
PPTX
How to Configure Prepayments in Odoo 18 Sales
Celine George
 
PPTX
Latest Features in Odoo 18 - Odoo slides
Celine George
 
PPSX
HEALTH ASSESSMENT (Community Health Nursing) - GNM 1st Year
Priyanshu Anand
 
PPTX
HEAD INJURY IN CHILDREN: NURSING MANAGEMENGT.pptx
PRADEEP ABOTHU
 
PDF
CEREBRAL PALSY: NURSING MANAGEMENT .pdf
PRADEEP ABOTHU
 
PPTX
CONVULSIVE DISORDERS: NURSING MANAGEMENT.pptx
PRADEEP ABOTHU
 
PDF
DIGESTION OF CARBOHYDRATES,PROTEINS,LIPIDS
raviralanaresh2
 
PDF
BÀI TẬP BỔ TRỢ TIẾNG ANH 8 - GLOBAL SUCCESS - CẢ NĂM - NĂM 2024 (VOCABULARY, ...
Nguyen Thanh Tu Collection
 
PPTX
ROLE OF ANTIOXIDANT IN EYE HEALTH MANAGEMENT.pptx
Subham Panja
 
PDF
community health nursing question paper 2.pdf
Prince kumar
 
PPT
digestive system for Pharm d I year HAP
rekhapositivity
 
PPTX
LEGAL ASPECTS OF PSYCHIATRUC NURSING.pptx
PoojaSen20
 
PPTX
HYDROCEPHALUS: NURSING MANAGEMENT .pptx
PRADEEP ABOTHU
 
PPTX
Accounting Skills Paper-I, Preparation of Vouchers
Dr. Sushil Bansode
 
PPTX
How to Configure Access Rights of Manufacturing Orders in Odoo 18 Manufacturing
Celine George
 
PDF
ARAL_Orientation_Day-2-Sessions_ARAL-Readung ARAL-Mathematics ARAL-Sciencev2.pdf
JoelVilloso1
 
PPTX
How to Manage Access Rights & User Types in Odoo 18
Celine George
 
Views on Education of Indian Thinkers Mahatma Gandhi.pptx
ShrutiMahanta1
 
Health Planning in india - Unit 03 - CHN 2 - GNM 3RD YEAR.ppsx
Priyanshu Anand
 
Federal dollars withheld by district, charter, grant recipient
Mebane Rash
 
How to Configure Prepayments in Odoo 18 Sales
Celine George
 
Latest Features in Odoo 18 - Odoo slides
Celine George
 
HEALTH ASSESSMENT (Community Health Nursing) - GNM 1st Year
Priyanshu Anand
 
HEAD INJURY IN CHILDREN: NURSING MANAGEMENGT.pptx
PRADEEP ABOTHU
 
CEREBRAL PALSY: NURSING MANAGEMENT .pdf
PRADEEP ABOTHU
 
CONVULSIVE DISORDERS: NURSING MANAGEMENT.pptx
PRADEEP ABOTHU
 
DIGESTION OF CARBOHYDRATES,PROTEINS,LIPIDS
raviralanaresh2
 
BÀI TẬP BỔ TRỢ TIẾNG ANH 8 - GLOBAL SUCCESS - CẢ NĂM - NĂM 2024 (VOCABULARY, ...
Nguyen Thanh Tu Collection
 
ROLE OF ANTIOXIDANT IN EYE HEALTH MANAGEMENT.pptx
Subham Panja
 
community health nursing question paper 2.pdf
Prince kumar
 
digestive system for Pharm d I year HAP
rekhapositivity
 
LEGAL ASPECTS OF PSYCHIATRUC NURSING.pptx
PoojaSen20
 
HYDROCEPHALUS: NURSING MANAGEMENT .pptx
PRADEEP ABOTHU
 
Accounting Skills Paper-I, Preparation of Vouchers
Dr. Sushil Bansode
 
How to Configure Access Rights of Manufacturing Orders in Odoo 18 Manufacturing
Celine George
 
ARAL_Orientation_Day-2-Sessions_ARAL-Readung ARAL-Mathematics ARAL-Sciencev2.pdf
JoelVilloso1
 
How to Manage Access Rights & User Types in Odoo 18
Celine George
 

How to build Android Chat App with Firebase for 2 hours?

  • 2. Nguyen Ba Thanh u Mobile App/Game Expert u CoFounder & CEO WePlay u Products u TOP 50 BlueBirdAward 2015 u “Bat Chu” – 10M Downloads 2015 u “Lich Van Nien” – 5M Downloads 2015 - Leading the Viet calendar mobile market for now thanhnotes.com NGUYEN BA THANH fb.com/thanhnb1101 thanhnotes.com [email protected] 0975.705.669
  • 3. Lecture Structure 1. Firebase Introduction 2. Demo ChatApp 3. [Key Notes] Firebase technical for ChatApp 4. [Guide] Step by step to build ChatApp with Firebase thanhnotes.com
  • 4. 1. 3 key values you will get? 3 key values you will get? 1. Knowledge Firebase basic 2. Know-how to create app on Android Studio 3. Know-how to create Android ChatApp with Firebase for million users thanhnotes.com
  • 5. 2. Firebase Introduction u A powerful platform for your mobile or web application u Build cross-platform native mobile/web apps with Android, iOS, and JavaScript SDKs thanhnotes.com
  • 6. 2. Firebase Introduction thanhnotes.com
  • 7. 3. Demo ChatApp u Demo ChatApp thanhnotes.com
  • 8. 4. [Key Notes] Firebase technical 1. Create an account 2. Install Firebase 3. Add Android permission 4. Setup Firebase on Android 5. Read/Write to Firebase Database 6. Authenticate users 7. Secure data thanhnotes.com
  • 9. 4. [Key Notes] Firebase technical 1. Create an account 2. Install Firebase 3. Add Android permission 4. Setup Firebase on Android 5. Read/Write to Firebase Database 6. Authenticate users 7. Secure data thanhnotes.com Link to registry: https://www.firebase.com/signup/
  • 10. 4. [Key Notes] Firebase technical 1. Create an account 2. Install Firebase 3. Add Android permission 4. Setup Firebase on Android 5. Read/Write to Firebase Database 6. Authenticate users 7. Secure data thanhnotes.com Download Firebase SDK: edit build.gradle & rebuild
  • 11. 4. [Key Notes] Firebase technical 1. Create an account 2. Install Firebase 3. Add Android permission 4. Setup Firebase on Android 5. Read/Write to Firebase Database 6. Authenticate users 7. Secure data thanhnotes.com Add  permission  INTERNET  to  AndroidManifest.xml
  • 12. 4. [Key Notes] Firebase technical 1. Create an account 2. Install Firebase 3. Add Android permission 4. Setup Firebase on Android 5. Read/Write to Firebase Database 6. Authenticate users 7. Secure data thanhnotes.com Add to your activity (in this case, it’s MainActivity.java)
  • 13. 4. [Key Notes] Firebase technical 1. Create an account 2. Install Firebase 3. Add Android permission 4. Setup Firebase on Android 5. Read/Write to Firebase Database 6. Authenticate users 7. Secure data thanhnotes.com 5.1. Create a reference to Firebase database 5.2. Write data 5.3. Read data
  • 14. 4. [Key Notes] Firebase technical 1. Create an account 2. Install Firebase 3. Add Android permission 4. Setup Firebase on Android 5. Read/Write to Firebase Database 6. Authenticate users 7. Secure data thanhnotes.com 1. Choose the Login & Auth tab. 2. Select the Email & Password tab and enable authentication.
  • 15. 4. [Key Notes] Firebase technical 1. Create an account 2. Install Firebase 3. Add Android permission 4. Setup Firebase on Android 5. Read/Write to Firebase Database 6. Authenticate users 7. Secure data thanhnotes.com
  • 16. 5. [Guide] Build ChatApp Firebase Prepare: Download and extract files to your computer: http://bit.ly/chatappvtc thanhnotes.com
  • 17. 5. [Guide] Build ChatApp Firebase Step 1. Create ChatApp by Anroid Studio Step 2. Install Firebase Step 3. Add Android permission Step 4. Create UI & implement Step 5. Prepare classes to get data Step 6. Setup Firebase Step 7. Connect database Step 8. Login with Firebase Step 9. Get messages to listview Step 10. Send message thanhnotes.com
  • 18. 5. [Guide] Build ChatApp Firebase Step 1. Create ChatApp by Anroid Studio Step 2. Install Firebase Step 3. Add Android permission Step 4. Create UI & implement Step 5. Prepare classes to get data Step 6. Setup Firebase Step 7. Connect database Step 8. Login with Firebase Step 9. Get messages to listview Step 10. Send message 1. Launch  Android  Studio 2.  File  -­>  New  -­>  New  Project 3.  Fill  infomation  of  project  and  finish 4.  Try  to  run  on  simulator  or  real  device   thanhnotes.com
  • 19. 5. [Guide] Build ChatApp Firebase Step 1. Create ChatApp by Anroid Studio Step 2. Install Firebase Step 3. Add Android permission Step 4. Create UI & implement Step 5. Prepare classes to get data Step 6. Setup Firebase Step 7. Connect database Step 8. Login with Firebase Step 9. Get messages to listview Step 10. Send message Add this code to build.gradle (app) and rebuild project to download Firebase SDK dependencies { compile 'com.firebase:firebase-client-android:2.5.1+’ } //You can copy this codes in file step2.txt thanhnotes.com
  • 20. 5. [Guide] Build ChatApp Firebase Step 1. Create ChatApp by Anroid Studio Step 2. Install Firebase Step 3. Add Android permission Step 4. Create UI & implement Step 5. Prepare classes to get data Step 6. Setup Firebase Step 7. Connect database Step 8. Login with Firebase Step 9. Get messages to listview Step 10. Send message Add more this code to AndroidManifests.xml file (code in file step3.txt) thanhnotes.com
  • 21. 5. [Guide] Build ChatApp Firebase Step 1. Create ChatApp by Anroid Studio Step 2. Install Firebase Step 3. Add Android permission Step 4. Create UI & implement Step 5. Prepare classes to get data Step 6. Setup Firebase Step 7. Connect database Step 8. Login with Firebase Step 9. Get messages to listview Step 10. Send message Copy 3 file xml in folder “ShareResource/layout” to your layout folder of your project and fill code to MainActivity.java as step4.txt thanhnotes.com
  • 22. 5. [Guide] Build ChatApp Firebase Step 1. Create ChatApp by Anroid Studio Step 2. Install Firebase Step 3. Add Android permission Step 4. Create UI & implement Step 5. Prepare classes to get data Step 6. Setup Firebase Step 7. Connect database Step 8. Login with Firebase Step 9. Get messages to listview Step 10. Send message Copy 2 classes: FirebaseListAdapter.java and Message.java into your project (app/java/vtc.edu.vn.vtcchatapp/) thanhnotes.com
  • 23. 5. [Guide] Build ChatApp Firebase Step 1. Create ChatApp by Anroid Studio Step 2. Install Firebase Step 3. Add Android permission Step 4. Create UI & implement Step 5. Prepare classes to get data Step 6. Setup Firebase Step 7. Connect database Step 8. Login with Firebase Step 9. Get messages to listview Step 10. Send message Copy this code to your MainActivity.java Firebase.setAndroidContext(this); thanhnotes.com (refer code in step6.txt)
  • 24. 5. [Guide] Build ChatApp Firebase Step 1. Create ChatApp by Anroid Studio Step 2. Install Firebase Step 3. Add Android permission Step 4. Create UI & implement Step 5. Prepare classes to get data Step 6. Setup Firebase Step 7. Connect database Step 8. Login with Firebase Step 9. Get messages to listview Step 10. Send message Step 7.1. Define variables in MainActivity.java Step 7.2. Add below code to MainActivity.java thanhnotes.com
  • 25. 5. [Guide] Build ChatApp Firebase Step 1. Create ChatApp by Anroid Studio Step 2. Install Firebase Step 3. Add Android permission Step 4. Create UI & implement Step 5. Prepare classes to get data Step 6. Setup Firebase Step 7. Connect database Step 8. Login with Firebase Step 9. Get messages to listview Step 10. Send message Copy code in file step8.txt to mLoginButton.setOnClickListener thanhnotes.com
  • 26. 5. [Guide] Build ChatApp Firebase Step 1. Create ChatApp by Anroid Studio Step 2. Install Firebase Step 3. Add Android permission Step 4. Create UI & implement Step 5. Prepare classes to get data Step 6. Setup Firebase Step 7. Connect database Step 8. Login with Firebase Step 9. Get messages to listview Step 10. Send message Step 9.1. Define variable FirebaseListAdapter Step 9.2. Get messages to adapter and display to listview Copy code in step9.txt thanhnotes.com
  • 27. 5. [Guide] Build ChatApp Firebase Step 1. Create ChatApp by Anroid Studio Step 2. Install Firebase Step 3. Add Android permission Step 4. Create UI & implement Step 5. Prepare classes to get data Step 6. Setup Firebase Step 7. Connect database Step 8. Login with Firebase Step 9. Get messages to listview Step 10. Send message Add code in step10.txt to mSend.setOnClickListener thanhnotes.com
  • 28. 5. [Guide] Build ChatApp Firebase Step 1. Create ChatApp by Anroid Studio Step 2. Install Firebase Step 3. Add Android permission Step 4. Create UI & implement Step 5. Prepare classes to get data Step 6. Setup Firebase Step 7. Connect database Step 8. Login with Firebase Step 9. Get messages to listview Step 10. Send message Final: Run thanhnotes.com