owncloud/core — pull request #2618 by Crazyphil (2013-03-30 13:05:21+00:00)
Title: Files External: allow dynamic backend registration

As discussed in pull request https://github.com/owncloud/core/pull/2180, I've modified the files_external app to dynamically register backends instead of using a hard-coded list. I've also moved dependency checks into the backend code (where they belong IMO) instead of the OC_Mount_Config class.

External backends will have to register in their app.php, for example:
```php
if (OC_App::isEnabled('files_external')) {
OC::$CLASSPATH['OC\Files\Storage\RapidShare'] = 'apps/files_external_rapidshare/lib/rapidshare.php';
OC_Mount_Config::registerBackend('OC\Files\Storage\RapidShare', array(
'backend' => 'RapidShare',
'configuration' => array(
'user' => 'Username',
'password' => '*Password',
'root' => '&Root')));
}
```

Until issue #1235 is closed, external backends also will have to make sure that the files_external app was already loaded (which is not the case when the administrator first enables the backend app and then the files_external app) by calling
```php
OC_App::loadApp('files_external');
```