How prudhvir3ddy/rideshare works
Project type and purpose
• This is an Android “ride-sharing” (Uber/Lyft clone) mobile app built in Kotlin, using Google Maps/Directions/Places APIs to fetch and render routes, and employing a simulated WebSocket “backend” to deliver real-time vehicle data and booking events. It follows a basic Model-View-Presenter (MVP) pattern, split into two Gradle modules:
• app (the mobile client)
• simulator (the WebSocket server emulator)
File structure
Top-level:
• app/ – Android application module
– src/main/java/com/prudhvir3ddy/rideshare/ui/maps → MapsActivity (View), MapsPresenter, MapsView interface
– src/main/java/com/prudhvir3ddy/rideshare/data/network → NetworkService (WebSocket client abstraction)
– src/main/java/com/prudhvir3ddy/rideshare/utils → animation, permission, map helper classes
– res/ → layouts, drawables, values (UI assets & configuration)
• simulator/ – backend simulator module
– src/main/java/com/mindorks/ridesharing/simulator → Simulator (establishes WebSocket server behavior), WebSocket, WebSocketListener
• build scripts and Gradle wrappers
README for additional insights
• Features: “nearby cabs,” “pickup/drop selection,” “cab booking,” “live car animation,” “trip lifecycle (start/end),” all delivered over a simulated WebSocket API.
• Architecture: Explicitly uses MVP in the client, and a simple WebSocket protocol simulator on the server module.
• External dependencies: Google Maps SDK (map display), Directions API (route geometry), Places API (geocoding), Android FusedLocationProvider.