forked from notmyname/php-cloudfiles
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Conrad Weidenkeller
committed
May 31, 2012
1 parent
5b45176
commit 930eb8d
Showing
45 changed files
with
12,107 additions
and
5,205 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,6 @@ | ||
1.7.11 Conrad Weidenkeller <[email protected]> | ||
* Added Temp URL Functionality. | ||
|
||
1.7.10 Conrad Weidenkeller <[email protected]> | ||
* Added Streaming URI Functionality | ||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -921,7 +921,7 @@ class CF_Container | |
public $name; | ||
public $object_count; | ||
public $bytes_used; | ||
|
||
public $metadata; | ||
public $cdn_enabled; | ||
public $cdn_streaming_uri; | ||
public $cdn_ssl_uri; | ||
|
@@ -959,6 +959,7 @@ function __construct(&$cfs_auth, &$cfs_http, $name, $count=0, | |
$this->name = $name; | ||
$this->object_count = $count; | ||
$this->bytes_used = $bytes; | ||
$this->metadata = array(); | ||
$this->cdn_enabled = NULL; | ||
$this->cdn_uri = NULL; | ||
$this->cdn_ssl_uri = NULL; | ||
|
@@ -2461,6 +2462,7 @@ function save_to_filename($filename) | |
* $obj->purge_from_cdn(); | ||
* # or | ||
* $obj->purge_from_cdn("[email protected],[email protected]"); | ||
* </code> | ||
* @returns boolean True if successful | ||
* @throws CDNNotEnabledException if CDN Is not enabled on this connection | ||
* @throws InvalidResponseException if the response expected is not returned | ||
|
@@ -2567,6 +2569,27 @@ private function _initialize() | |
$this->manifest = $manifest; | ||
return True; | ||
} | ||
/** | ||
* Generate a Temp Url for a object | ||
* Example: | ||
* <code> | ||
* # ... authentication code excluded (see previous examples) ... | ||
* $conn = new CF_Connection($auth); | ||
* $container = $conn->get_container("foo"); | ||
* $obj = $container->get_object("foo"); | ||
* $obj->get_tmp_url("shared secret, $expire_time_in_seconds, "HTTP_METHOD" | ||
* </code> | ||
* @returns The temp url | ||
*/ | ||
public function get_temp_url($key, $expires, $method) | ||
{ | ||
|
||
$expires += time(); | ||
$url = $this->container->cfs_http->getStorageUrl() . '/' . $this->container->name . '/' . $this->name; | ||
return $url . '?temp_url_sig=' . hash_hmac('sha1', strtoupper($method) . | ||
"\n" . $expires . "\n" . parse_url($url, PHP_URL_PATH), $key) . | ||
'&temp_url_expires=' . $expires; | ||
} | ||
|
||
#private function _re_auth() | ||
#{ | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,59 @@ | ||
<html> | ||
<head> | ||
<title>Class Trees for Package php-cloudfiles-exceptions</title> | ||
<link rel="stylesheet" type="text/css" href="media/style.css"> | ||
</head> | ||
<body> | ||
|
||
<table border="0" cellspacing="0" cellpadding="0" height="48" width="100%"> | ||
<tr> | ||
<td class="header_top">php-cloudfiles-exceptions</td> | ||
</tr> | ||
<tr><td class="header_line"><img src="media/empty.png" width="1" height="1" border="0" alt="" /></td></tr> | ||
<tr> | ||
<td class="header_menu"> | ||
|
||
|
||
[ <a href="classtrees_php-cloudfiles-exceptions.html" class="menu">class tree: php-cloudfiles-exceptions</a> ] | ||
[ <a href="elementindex_php-cloudfiles-exceptions.html" class="menu">index: php-cloudfiles-exceptions</a> ] | ||
[ <a href="elementindex.html" class="menu">all elements</a> ] | ||
</td> | ||
</tr> | ||
<tr><td class="header_line"><img src="media/empty.png" width="1" height="1" border="0" alt="" /></td></tr> | ||
</table> | ||
|
||
<table width="100%" border="0" cellpadding="0" cellspacing="0"> | ||
<tr valign="top"> | ||
<td width="200" class="menu"> | ||
<div id="ric"> | ||
<p><a href="ric_AUTHORS.html">AUTHORS</a></p> | ||
<p><a href="ric_README.html">README</a></p> | ||
<p><a href="ric_COPYING.html">COPYING</a></p> | ||
<p><a href="ric_Changelog.html">Changelog</a></p> | ||
</div> | ||
<b>Packages:</b><br /> | ||
<a href="li_php-cloudfiles.html">php-cloudfiles</a><br /> | ||
<a href="li_php-cloudfiles-exceptions.html">php-cloudfiles-exceptions</a><br /> | ||
<a href="li_php-cloudfiles-http.html">php-cloudfiles-http</a><br /> | ||
<br /><br /> | ||
</td> | ||
<td> | ||
<table cellpadding="10" cellspacing="0" width="100%" border="0"><tr><td valign="top"> | ||
|
||
<h1>Class Trees for Package php-cloudfiles-exceptions</h1> | ||
<hr /> | ||
<div class="classtree">Root class Exception</div><br /> | ||
<ul> | ||
<li><a href="php-cloudfiles-exceptions/AuthenticationException.html">AuthenticationException</a></li><li><a href="php-cloudfiles-exceptions/BadContentTypeException.html">BadContentTypeException</a></li><li><a href="php-cloudfiles-exceptions/CDNNotEnabledException.html">CDNNotEnabledException</a></li><li><a href="php-cloudfiles-exceptions/ConnectionNotOpenException.html">ConnectionNotOpenException</a></li><li><a href="php-cloudfiles-exceptions/InvalidResponseException.html">InvalidResponseException</a></li><li><a href="php-cloudfiles-exceptions/InvalidUTF8Exception.html">InvalidUTF8Exception</a></li><li><a href="php-cloudfiles-exceptions/IOException.html">IOException</a></li><li><a href="php-cloudfiles-exceptions/MisMatchedChecksumException.html">MisMatchedChecksumException</a></li><li><a href="php-cloudfiles-exceptions/NonEmptyContainerException.html">NonEmptyContainerException</a></li><li><a href="php-cloudfiles-exceptions/NoSuchAccountException.html">NoSuchAccountException</a></li><li><a href="php-cloudfiles-exceptions/NoSuchContainerException.html">NoSuchContainerException</a></li><li><a href="php-cloudfiles-exceptions/NoSuchObjectException.html">NoSuchObjectException</a></li><li><a href="php-cloudfiles-exceptions/SyntaxException.html">SyntaxException</a></li></ul> | ||
|
||
<div class="credit"> | ||
<hr /> | ||
Documentation generated on Thu, 31 May 2012 05:57:25 -0500 by <a href="http://www.phpdoc.org">phpDocumentor 1.4.1</a> | ||
</div> | ||
</td></tr></table> | ||
</td> | ||
</tr> | ||
</table> | ||
|
||
</body> | ||
</html> |
Oops, something went wrong.