alexmamo / FireApp

FirebaseApp is built for learning purposes, especially to see how Firebase Products work together.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

FireApp - Clean Architecture

FireApp is an open-source project that is built around Firebase Products, especially for learning purposes. This application is written entirely in Kotlin using Android Architecture Components and MVVM architecture pattern. You'll see in the code of this repo, how Firebase Products are working together.

Below you can find the docs for each tehnology that is used in this app:

Firebase Products:

Android Architecture Components:

Dependency Injection:

Asynchronous Programming:

Other Android Components:

Other Libraries:

If you download or clone this repo, in order to make it work, you should follow the instructions given in the official documentation regarding on how to add Firebase to your project.

In case of Cloud Firestore, you can use a List of Movie objects as below:

val movies = listOf(
    Movie("A Love Affair In Transit", 1994, 9.2, "", "Lorem Ipsum is simply dummy text of the printing and typesetting industry."),
    Movie("Adrift", 1972, 9.1, "", "Lorem Ipsum is simply dummy text of the printing and typesetting industry."),
    Movie("All About You", 1974, 9.0, "", "Lorem Ipsum is simply dummy text of the printing and typesetting industry."),
    Movie("Blood Bone And Beasts", 2008, 9.0, "", "Lorem Ipsum is simply dummy text of the printing and typesetting industry."),
    Movie("Changing To Victory", 1957, 8.9, "", "Lorem Ipsum is simply dummy text of the printing and typesetting industry."),
    Movie("Down The Rabbit Hole", 1993, 8.9, "", "Lorem Ipsum is simply dummy text of the printing and typesetting industry."),
    Movie("En Route", 2003, 8.9, "", "Lorem Ipsum is simply dummy text of the printing and typesetting industry."),
    Movie("Into The Darkness", 1994, 8.8, "", "Lorem Ipsum is simply dummy text of the printing and typesetting industry."),
    Movie("Lighting Shadows", 1966, 8.8, ", "Lorem Ipsum is simply dummy text of the printing and typesetting industry.""),
    Movie("Locked", 2001, 8.8, "", "Lorem Ipsum is simply dummy text of the printing and typesetting industry."),
    Movie("Lost Girl", 1999, 8.8, "", "Lorem Ipsum is simply dummy text of the printing and typesetting industry."),
    Movie("Love Africa", 1994, 8.7, "", "Lorem Ipsum is simply dummy text of the printing and typesetting industry."),
    Movie("Movie Night", 2010, 8.7, ""),
    Movie("Outdoor Movie Night", 2002, 8.7, "", "Lorem Ipsum is simply dummy text of the printing and typesetting industry."),
    Movie("She", 1980, 8.7, "", "Lorem Ipsum is simply dummy text of the printing and typesetting industry."),
    Movie("The Great Big Bridge", 1999, 8.6, "", "Lorem Ipsum is simply dummy text of the printing and typesetting industry."),
    Movie("The Life Of Richard Parker", 1990, 8.6, "", "Lorem Ipsum is simply dummy text of the printing and typesetting industry."),
    Movie("The Lost Girl", 1975, 8.6, "", "Lorem Ipsum is simply dummy text of the printing and typesetting industry."),
    Movie("The Love Of Mine", 1954, 8.6, "", "Lorem Ipsum is simply dummy text of the printing and typesetting industry."),
    Movie("The Night Is Young", 1995, 8.6, "", "Lorem Ipsum is simply dummy text of the printing and typesetting industry."),
    Movie("The Walk", 1991, 8.6, "", "Lorem Ipsum is simply dummy text of the printing and typesetting industry."),
    Movie("The Way We Get By", 2002, 8.6, "", "Lorem Ipsum is simply dummy text of the printing and typesetting industry."),
    Movie("Thriller Movie Night", 1946, 8.6, "", "Lorem Ipsum is simply dummy text of the printing and typesetting industry."),
    Movie("Top Of The World", 1997, 8.6, "", "Lorem Ipsum is simply dummy text of the printing and typesetting industry."),
    Movie("Train To Hell", 1977, 8.6, "", "Lorem Ipsum is simply dummy text of the printing and typesetting industry."),
)

As you can see, there is no URL in the Movie object, so you should populate that value your self. Here is an [archive][]. You can do it using Cloud Storage as I did, or any other Hosting Service. In case of the Realtime Database, you can use the same list, but you should change the value of "rating" to a negative one. Why? So we can simply order the results accoding to that field.

alt text

You can also check the following article writen on Mediul publication:

License

The code in this project is licensed under the Apache License 2.0.

Copyright 2018 Google LLC

Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at

https://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.

Disclaimer

  • This is not an officially supported Google product.

About

FirebaseApp is built for learning purposes, especially to see how Firebase Products work together.


Languages

Language:Kotlin 100.0%