Ejemplo n.º 1
0
 public function __construct($logger)
 {
     $this->logger = $logger;
     $this->map = new Map($logger);
     $this->wordpress = new \WPUtilities\WordPressWrapper();
     $this->httpEngine = new \HttpExchange\Adapters\Resty(new \Resty\Resty());
     $this->apiBase = \WPUtilities\API::getApiBase();
 }
Ejemplo n.º 2
0
 public function fetch($id)
 {
     $apiBase = \WPUtilities\API::getApiBase();
     $map = $this->api->get("/{$id}")->data;
     return $map->meta->locations;
 }
Ejemplo n.º 3
0
 public function __construct()
 {
     $this->http = new \HttpExchange\Adapters\Resty(new \Resty());
     $this->apiBase = \WPUtilities\API::getApiBase();
 }