You are here

class NullPartner in Lockr 7.2

Hierarchy

Expanded class hierarchy of NullPartner

1 file declares its use of NullPartner
lockr.module in ./lockr.module
Hook implementations and callbacks for lockr.

File

vendor/lockr/lockr-client/src/NullPartner.php, line 6

Namespace

Lockr
View source
class NullPartner implements PartnerInterface {

  /**
   * @var string The Lockr region.
   */
  protected $region;

  /**
   * Constucts the partner.
   */
  public function __construct($region = 'us') {
    $this->region = $region;
  }

  /**
   * {@inheritdoc}
   */
  public function requestOptions() {
    return array();
  }

  /**
   * {@inheritdoc}
   */
  public function getReadUri() {
    if ($this->region != 'us') {
      return "https://{$this->region}.custom.api.lockr.io";
    }
    return "https://custom.api.lockr.io";
  }

  /**
   * {@inheritdoc}
   */
  public function getWriteUri() {
    if ($this->region != 'us') {
      return "https://{$this->region}.custom.api.lockr.io";
    }
    return "https://custom.api.lockr.io";
  }

  /**
   * {@inheritdoc}
   */
  public function getAccountingUri() {
    return "https://custom.api.lockr.io";
  }

}

Members

Namesort descending Modifiers Type Description Overrides
NullPartner::$region protected property
NullPartner::getAccountingUri public function
NullPartner::getReadUri public function Gets the partner base URI for reading data. Overrides PartnerInterface::getReadUri
NullPartner::getWriteUri public function Gets the partner base URI for writing data. Overrides PartnerInterface::getWriteUri
NullPartner::requestOptions public function Adds required request options to the request for partner authentication. Overrides PartnerInterface::requestOptions
NullPartner::__construct public function Constucts the partner.