How rainhacker/locator works
Main Components
A. Client Layer:
• Web Browser (User Interface)
• Google Maps Integration
• Bootstrap UI Framework
B. Web Layer:
• JSP Pages (home.jsp, showMap.jsp)
• MapServlet (Controller)
C. Business Layer:
• Location Service Components
• Location Selector System
• CSV Data Processing
D. Data Layer:
• NYC WiFi Hotspot CSV File
• Google Maps API Integration
[Top Layer]
Client Layer (Web Browser)
[Middle Layers]
Web Layer (Servlets & JSPs)
Business Layer (Location Processing)
[Bottom Layer]
Data Layer (CSV & External APIs)
Component Relationships to Highlight
• Client → Web Layer (HTTP Requests)
• Web Layer → Business Layer (Java Method Calls)
• Business Layer → Data Layer (File Reading & API Calls)
• Business Layer → Google Maps API (External Service)
B. Include these specific components:
• MapServlet as the main controller
• Location Selector hierarchy (AbstractLocationSelector, NearestOneLocationSelector, NearestNlocationSelector)
• LocationSelectorSimpleFactory for instantiation
• CSV Data Store (NYC_Free_Public_WiFi_12052014.csv)
Specific Implementation Details
A. Client Layer:
• Bootstrap UI components
• Google Maps JavaScript integration
• User interaction points (1 or 10 nearest locations selection)
B. Web Layer:
• MapServlet as the main controller
• JSP view templates
• Request/response flow
C. Business Layer:
• Detail the Location Selector pattern
• Factory pattern implementation
• Location processing logic
D. Data Layer:
• CSV data source
• Google Maps API integration points