original_string: public function getAddresses(CoordinatesInterface $coordinates) : AddressCollection
      {
          $url = $this->coordinatesQuery($coordinates);
          $json = $this->fetchUrl($url);
  
          // convert google data to address collection
          $results = [];
          foreach ($json->results as $result) {
              $address = AddressBuild::create($result);
              $address->setCoordinates($coordinates);
              $results[] = $address;
          }
  
          return new AddressCollection($results);
      }
code: public function getAddresses(CoordinatesInterface $coordinates) : AddressCollection
      {
          $url = $this->coordinatesQuery($coordinates);
          $json = $this->fetchUrl($url);
  
          // convert google data to address collection
          $results = [];
          foreach ($json->results as $result) {
              $address = AddressBuild::create($result);
              $address->setCoordinates($coordinates);
              $results[] = $address;
          }
  
          return new AddressCollection($results);
      }
code_tokens: public function getAddresses ( CoordinatesInterface $ coordinates ) : AddressCollection { $ url = $ this -> coordinatesQuery ( $ coordinates ) ; $ json = $ this -> fetchUrl ( $ url ) ; // convert google data to address collection $ results = [ ] ; foreach ( $ json -> results as $ result ) { $ address = AddressBuild :: create ( $ result ) ; $ address -> setCoordinates ( $ coordinates ) ; $ results [ ] = $ address ; } return new AddressCollection ( $ results ) ; }
docstring: Get possible addresses using CoordinatesInterface
  
  @param CoordinatesInterface $coordinates
  @return AddressCollection
docstring_tokens: Get possible addresses using CoordinatesInterface