Services_OpenStreetMap

# Class: Services_OpenStreetMap_Transport_HTTPCached

Source Location: /OpenStreetMap/Transport/HTTPCached.php

### Class Overview

    Services_OpenStreetMap_Transport_HTTP
       |
       --Services_OpenStreetMap_Transport_HTTPCached

Services_OpenStreetMap_Transport_HTTPCached

#### Author(s):

- Ken Guest <kguest@php.net>

### Variables

- $cache

### Methods

- __construct
- getResponse
- setCache

### Inherited Variables

#### Class: Services_OpenStreetMap_Transport_HTTP

Services_OpenStreetMap_Transport_HTTP::$config
Services_OpenStreetMap_Transport_HTTP::$log
Services_OpenStreetMap_Transport_HTTP::$request

### Inherited Methods

#### Class: Services_OpenStreetMap_Transport_HTTP

Services_OpenStreetMap_Transport_HTTP::__construct()
  __construct
Services_OpenStreetMap_Transport_HTTP::getConfig()
  Get current Config object
Services_OpenStreetMap_Transport_HTTP::getObject()
  getObject
Services_OpenStreetMap_Transport_HTTP::getObjects()
  getObjects
Services_OpenStreetMap_Transport_HTTP::getRequest()
  Get HTTP_Request2 instance.
Services_OpenStreetMap_Transport_HTTP::getResponse()
  Send request to OSM server and return the response.
Services_OpenStreetMap_Transport_HTTP::searchObjects()
  searchObjects
Services_OpenStreetMap_Transport_HTTP::setConfig()
  Set Config object
Services_OpenStreetMap_Transport_HTTP::setLog()
  set Log object
Services_OpenStreetMap_Transport_HTTP::setRequest()
  Set the HTTP_Request2 instance and return the Services_OpenStreetMap instance.

### Class Details

[line 27]
Services_OpenStreetMap_Transport_HTTPCached

#### Tags:

author: | Ken Guest <kguest@php.net>
link: | HTTPCached.php
license: | BSD

[ Top ]

### Class Variables

#### $cache =

[line 31]

#### Tags:

access: | protected

Type: | mixed

[ Top ]

### Class Methods

### constructor __construct [line 38]

`Services_OpenStreetMap_Transport_HTTPCached __construct( )`

__construct

#### Tags:

access: | public

Overrides Services_OpenStreetMap_Transport_HTTP::__construct() (__construct)
[ Top ]

### method getResponse [line 76]

`HTTP_Request2_Response getResponse( string $url, [string $method = HTTP_Request2::METHOD_GET], [string $user = null], [string $password = null], [string $body = null], [array $post_data = null], [array $headers = null])`

Send request to OSM server and return the response.

#### Tags:

todo: | Consider just returning the content?
throws: | Services_OpenStreetMap_Exception If something unexpected has happened while conversing with the server.
access: | public

Overrides Services_OpenStreetMap_Transport_HTTP::getResponse() (Send request to OSM server and return the response.)

#### Parameters:

string | $url | URL
string | $method | GET (default)/POST/PUT
string | $user | user (optional for read-only actions)
string | $password | password (optional for read-only actions)
string | $body | body (optional)
array | $post_data | (optional)
array | $headers | (optional)

[ Top ]

### method setCache [line 52]

`Services_OpenStreetMap_Transport_HTTPCached setCache( Cache $cache)`

setCache

#### Tags:

access: | public

#### Parameters:

Cache | $cache | Cache object

[ Top ]

Documentation generated on Wed, 26 Sep 2012 01:24:52 +0100 by phpDocumentor 1.4.4