Skip to content

This android app provides weather info for multiple cities, including current, 48h, and 8d forecasts. It can also detect user's location for accurate local weather.

License

Notifications You must be signed in to change notification settings

yassineAbou/Weather

Repository files navigation

Weather

Weather

Kotlin version 1.8.21 Gradle version 8.0.2 Android Studio Flamingo Android min version 7

Users can view and add weather information for multiple cities of their choice with this app.
It provides a 48-hour forecast, an 8-day forecast, and current weather conditions.
The program can also detect the user’s location to provide accurate local weather information.

Get it on Google Play

Screenshots

API

This project uses the Open-Meteo API to fetch weather data.

Architecture

The architecture of this application relies and complies with the following points below:

  • A single-activity architecture, using the ViewPager2 to display a collection of fragments in a scrollable, swipeable interface.
  • Pattern Model-View-ViewModel(MVVM) which facilitates a separation of development of the graphical user interface.
  • Android architecture components which help to keep the application robust, testable, and maintainable.

Package Structure

com.yassineabou.weather        # Root package  
├── data                   # For data modeling layer  
│   ├── local              # Local persistence database  
|   ├── model              # Model classes  
│   ├── remote             # Remote data source  
│   └── repository         # Repositories for single source of data  
|  
├── di                     # Dependency injection modules  
│  
├── ui                     # Activity / Fragment / ViewModel  
│   ├── addLocation        # Allows user to add new locations
│   ├── currentWeather     # Presents current weather details
|   ├── dailyForecast      # Showcases daily weather forecast
|   ├── hourlyForecast     # Illustrates hourly weather forecast  
|   ├── listLocations      # Lists saved locations
|   ├── PagerAdapter       # Adapter for viewPager2  
|   ├── MainActivity       # Single activity  
│   └── MainViewModel      # Shared viewModel  
|  
├── utils                  # Utility classes / Kotlin extensions  
└── WeatherApplication     # Application  
  

Built With 🧰

Contribution

We welcome contributions to our project! Please follow these guidelines when submitting changes:

  • Report bugs and feature requests by creating an issue on our GitHub repository.
  • Contribute code changes by forking the repository and creating a new branch.
  • Ensure your code follows our coding conventions.
  • Improve our documentation by submitting changes as a pull request.

Thank you for your interest in contributing to our project!

License

Copyright 2023 Yassine Abou 
  
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  
  
    http://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.