/** * Add calculated coordinate for hash * * @param Model\Constraint|Model\Location $address * @param array $fields * * @throws \TYPO3\CMS\Core\Exception * @return void */ public function addCoordinateForAddress($address, $fields) { $coordinate = array('latitude' => $address->getLatitude(), 'longitude' => $address->getLongitude()); $hash = $this->getHashForAddressWithFields($address, $fields); if (count($fields) <= 3) { $this->setValueInCacheTable($hash, $coordinate); } else { $this->setValueInSession($hash, $coordinate); } }