mirror of
https://github.com/nextcloud/server.git
synced 2024-11-14 12:26:49 +00:00
dae7c159f7
Signed-off-by: Andy Scherzinger <info@andy-scherzinger.de>
27 lines
639 B
PHP
27 lines
639 B
PHP
<?php
|
|
/**
|
|
* SPDX-FileCopyrightText: 2017 Nextcloud GmbH and Nextcloud contributors
|
|
* SPDX-License-Identifier: AGPL-3.0-or-later
|
|
*/
|
|
namespace OC\Remote;
|
|
|
|
use OCP\Http\Client\IClientService;
|
|
use OCP\ICache;
|
|
use OCP\Remote\IInstanceFactory;
|
|
|
|
class InstanceFactory implements IInstanceFactory {
|
|
/** @var ICache */
|
|
private $cache;
|
|
/** @var IClientService */
|
|
private $clientService;
|
|
|
|
public function __construct(ICache $cache, IClientService $clientService) {
|
|
$this->cache = $cache;
|
|
$this->clientService = $clientService;
|
|
}
|
|
|
|
public function getInstance($url) {
|
|
return new Instance($url, $this->cache, $this->clientService);
|
|
}
|
|
}
|