Sanisette is an Android application built for a technical interview test. It provides a convenient way to locate and view public toilets (sanisettes) in Paris. The app offers two main views: a list view and a map view, allowing users to explore available facilities either as a list of details or as markers on a map.
-
List View
- Displays a detailed list of public toilets, including:
- Address
- Opening hours
- Manager
- District information
- Users can filter the list based on specific districts.
- Displays a detailed list of public toilets, including:
-
Map View
- Shows public toilets as markers on an interactive Google Map.
- Users can zoom in and out to explore the facilities in various parts of Paris.
-
Bottom Navigation Bar
- Provides easy navigation between the list view and the map view.
- Kotlin: The primary programming language for the app.
- Dependency Injection: Implemented using Koin for modular and testable code.
- Jetpack Compose: Used for building the user interface in a modern and declarative style.
- Paging 3: For efficient loading and pagination of large datasets in the list view.
- Google Maps Compose: For rendering the map view and markers.
- Coroutines: For managing asynchronous tasks, including API calls and data processing.
- MVVM Architecture: Ensures a clean separation of concerns using ViewModel and Repository patterns.
-
Data Source:
- The app fetches public toilet data from the OpenData Paris API: https://data.ratp.fr/api/records/1.0/search/?dataset=sanisettesparis2011
-
List View:
- Data is loaded using the Paging 3 library and displayed in a scrollable list.
- Each item in the list contains detailed information about a public toilet.
-
Map View:
- Uses Google Maps Compose to render markers based on the fetched data.
- Automatically adjusts the displayed markers based on the current map bounds and zoom level.
-
Search and Filtering:
- Users can search for public toilets by district.
- The search query is sent to the API, and the results update the list dynamically.
-
Pagination:
- The app implements API pagination to load data incrementally for better performance and user experience.
-
Clone the repository:
git clone https://github.com/maher000/sanisette.git
-
Open the project in Android Studio.
-
Build and run the project on an emulator or a physical device.
- Unit Tests:
- ViewModel tests ensure the correctness of business logic and API interactions.
- Launch the app.
- Use the bottom navigation bar to switch between the list view and the map view.
- Use district filter to narrow down the results.
- Add clustering for markers on the map to improve performance and readability when zoomed out.
- Improve loading sanisettes on the map
- improve navigation between screens
- Implement offline support for viewing public toilet data.
- Add more unit tests
Contributions are welcome! If you find any issues or have suggestions for improvement, please open an issue or submit a pull request.
If you have any questions or need further assistance, feel free to contact the repository owner.