get_config(); $endpoint = ('' != $region && 'n/a' != $region) ? $region : $config['endpoint']; global $updraftplus; if ($updraftplus->backup_time) $updraftplus->log("Set endpoint: $endpoint"); $obj->setEndpoint($endpoint); } /** * This method overrides the parent method and lists the supported features of this remote storage option. * * @return Array - an array of supported features (any features not mentioned are asuumed to not be supported) */ public function get_supported_features() { // This options format is handled via only accessing options via $this->get_options() return array('multi_options', 'config_templates', 'multi_storage'); } /** * Retrieve default options for this remote storage module. * * @return Array - an array of options */ public function get_default_options() { return array( 'accesskey' => '', 'secretkey' => '', 'path' => '', ); } /** * Retrieve specific options for this remote storage module * * @return Array - an array of options */ protected function get_config() { $opts = $this->get_options(); $opts['whoweare'] = 'DreamObjects'; $opts['whoweare_long'] = 'DreamObjects'; $opts['key'] = 'dreamobjects'; if (empty($opts['endpoint'])) $opts['endpoint'] = $this->dreamobjects_endpoints[0]; return $opts; } /** * Get the pre configuration template * * @return String - the template */ public function get_pre_configuration_template() { $this->get_pre_configuration_template_engine('dreamobjects', 'DreamObjects', 'DreamObjects', 'DreamObjects', 'https://panel.dreamhost.com/index.cgi?tree=storage.dreamhostobjects', ''); } /** * Get the configuration template * * @return String - the template, ready for substitutions to be carried out */ public function get_configuration_template() { return $this->get_configuration_template_engine('dreamobjects', 'DreamObjects', 'DreamObjects', 'DreamObjects', 'https://panel.dreamhost.com/index.cgi?tree=storage.dreamhostobjects', ''); } /** * Get handlebar partial template string for endpoint of s3 compatible remote storage method. Other child class can extend it. * * @return string the partial template string */ protected function get_partial_configuration_template_for_endpoint() { // When new endpoint introduced in future, Please add it as hard coded option for below endpoint dropdown and also add as array value in private $dreamobjects_endpoints variable return '