This article demonstrates how to connect an Android Application with Firebase DB.
Requirements
Follow the steps given below to build an Android Application
Now, download Google-Services.json file and add into your Application; app folder.
Add classpath plug-in into project gradle.
Now, go to Android Studio and copy the code.
activity_main.xml
MainActivity.java
Here, add your database URL.
Now go to firebase console choose database in menu and select "Rules" tab update the below code.
Please don’t forget to add Internet access permission on androidmanifest.xml.
Now, run your Application. Give the name and age, when you press ADD DATA button and the data will insert into the database.
In this article, we discussed about what Google Firebase is, and how to connect an Android app with Firebase DB. Also, we saw how to insert some values into the database.
Pro WPF: Windows Presentation Foundation in .NET 3.0