Overview

Classes

  • Dropbox\AppInfo
  • Dropbox\ArrayEntryStore
  • Dropbox\AuthBase
  • Dropbox\AuthInfo
  • Dropbox\Client
  • Dropbox\OAuth1AccessToken
  • Dropbox\OAuth1Upgrader
  • Dropbox\Path
  • Dropbox\RootCertificates
  • Dropbox\Security
  • Dropbox\SSLTester
  • Dropbox\Util
  • Dropbox\WebAuth
  • Dropbox\WebAuthBase
  • Dropbox\WebAuthNoRedirect
  • Dropbox\WriteMode

Interfaces

  • Dropbox\ValueStore

Exceptions

  • Dropbox\AppInfoLoadException
  • Dropbox\AuthInfoLoadException
  • Dropbox\DeserializeException
  • Dropbox\Exception
  • Dropbox\Exception_BadRequest
  • Dropbox\Exception_BadResponse
  • Dropbox\Exception_BadResponseCode
  • Dropbox\Exception_InvalidAccessToken
  • Dropbox\Exception_NetworkIO
  • Dropbox\Exception_OverQuota
  • Dropbox\Exception_ProtocolError
  • Dropbox\Exception_RetryLater
  • Dropbox\Exception_ServerError
  • Dropbox\HostLoadException
  • Dropbox\StreamReadException
  • Dropbox\WebAuthException_BadRequest
  • Dropbox\WebAuthException_BadState
  • Dropbox\WebAuthException_Csrf
  • Dropbox\WebAuthException_NotApproved
  • Dropbox\WebAuthException_Provider
  • Overview
  • Class

Interface ValueStore

A contract for a class which provides simple get/set/clear access to a single string value. Dropbox\ArrayEntryStore provides an implementation of this for storing a value in a single array element.

Example implementation for a Memcache-based backing store:

class MemcacheValueStore implements ValueStore
{
    private $key;
    private $memcache;

    function __construct($memcache, $key)
    {
        $this->memcache = $memcache;
        $this->key = $key;
    }

    function get()
    {
        $value = $this->memcache->get($this->getKey());
        return $value === false ? null : base64_decode($value);
    }

    function set($value)
    {
        $this->memcache->set($this->key, base64_encode($value));
    }

    function clear()
    {
        $this->memcache->delete($this->key);
    }
}

Direct known implementers

Dropbox\ArrayEntryStore
Namespace: Dropbox
Located at Dropbox/ValueStore.php
Methods summary
public string
# get( )

Returns the entry's current value or null if nothing is set.

Returns the entry's current value or null if nothing is set.

Returns

string
public
# set( string $value )

Set the entry to the given value.

Set the entry to the given value.

Parameters

$value
public
# clear( )

Remove the value.

Remove the value.

Dropbox SDK for PHP API documentation generated by ApiGen