apidoc
[ class tree: apidoc ] [ index: apidoc ] [ all elements ]

Class: Services_ExchangeRates_Transport_HTTP_Cached

Source Location: /Services_ExchangeRates-0.6.0/Services/ExchangeRates/Transport/HTTP_Cached.php

Class Overview




Variables

Methods


Inherited Variables

Inherited Methods


Class Details

[line 8]


[ Top ]


Class Variables

$cache =

[line 9]


Type:   mixed


[ Top ]



Method Detail

Services_ExchangeRates_Transport_HTTP_Cached (Constructor)   [line 11]

Services_ExchangeRates_Transport_HTTP_Cached Services_ExchangeRates_Transport_HTTP_Cached( $cache, $request)


Parameters:

   $cache   — 
   $request   — 

[ Top ]

fetch   [line 34]

string fetch( string $url)

Retrieves data from cache, if it's there. If it is, but it's expired,

it performs a conditional GET to see if the data is updated. If it isn't, it down updates the modification time of the cache file and returns the data. If the cache is not there, or the remote file has been modified, it is downloaded and cached.

  • Return: File contents

Parameters:

string   $url   —  URL of remote file to retrieve

[ Top ]


Documentation generated on Mon, 11 Mar 2019 15:28:43 -0400 by phpDocumentor 1.4.4. PEAR Logo Copyright © PHP Group 2004.