]> git.openstreetmap.org Git - nominatim.git/blob - lib-php/TokenCountry.php
Merge pull request #2284 from lonvia/cleanup-word-frequency-computation
[nominatim.git] / lib-php / TokenCountry.php
1 <?php
2
3 namespace Nominatim\Token;
4
5 /**
6  * A country token.
7  */
8 class Country
9 {
10     /// Database word id, if available.
11     public $iId;
12     /// Two-letter country code (lower-cased).
13     public $sCountryCode;
14
15     public function __construct($iId, $sCountryCode)
16     {
17         $this->iId = $iId;
18         $this->sCountryCode = $sCountryCode;
19     }
20
21     public function debugInfo()
22     {
23         return array(
24                 'ID' => $this->iId,
25                 'Type' => 'country',
26                 'Info' => $this->sCountryCode
27                );
28     }
29 }