/** * @return StationState[] */ public function getSnapshot() { $response = $this->browser->post(self::BICING_URL); $stations = $this->parse($response->getContent()); $time = new \DateTime(); return array_map(function ($element) use($time) { return StationState::constructFromApiData($element, $time); }, $stations); }