Signed-off-by: Hamid Dehnavi <hamid.dev.pro@gmail.com>tags/v29.0.0beta1
'prevent_group_restriction', | 'prevent_group_restriction', | ||||
]; | ]; | ||||
private IUserSession $userSession; | |||||
private IConfig $config; | |||||
private AppConfig $appConfig; | |||||
private IGroupManager $groupManager; | |||||
private ICacheFactory $memCacheFactory; | |||||
private IEventDispatcher $dispatcher; | |||||
private LoggerInterface $logger; | |||||
/** @var string[] $appId => $enabled */ | /** @var string[] $appId => $enabled */ | ||||
private array $installedAppsCache = []; | private array $installedAppsCache = []; | ||||
/** @var array<string, true> */ | /** @var array<string, true> */ | ||||
private array $loadedApps = []; | private array $loadedApps = []; | ||||
public function __construct(IUserSession $userSession, | |||||
IConfig $config, | |||||
AppConfig $appConfig, | |||||
IGroupManager $groupManager, | |||||
ICacheFactory $memCacheFactory, | |||||
IEventDispatcher $dispatcher, | |||||
LoggerInterface $logger) { | |||||
$this->userSession = $userSession; | |||||
$this->config = $config; | |||||
$this->appConfig = $appConfig; | |||||
$this->groupManager = $groupManager; | |||||
$this->memCacheFactory = $memCacheFactory; | |||||
$this->dispatcher = $dispatcher; | |||||
$this->logger = $logger; | |||||
public function __construct( | |||||
private IUserSession $userSession, | |||||
private IConfig $config, | |||||
private AppConfig $appConfig, | |||||
private IGroupManager $groupManager, | |||||
private ICacheFactory $memCacheFactory, | |||||
private IEventDispatcher $dispatcher, | |||||
private LoggerInterface $logger, | |||||
) { | |||||
} | } | ||||
/** | /** |
use OCP\IL10N; | use OCP\IL10N; | ||||
abstract class Bundle { | abstract class Bundle { | ||||
/** @var IL10N */ | |||||
protected $l10n; | |||||
/** | /** | ||||
* @param IL10N $l10n | * @param IL10N $l10n | ||||
*/ | */ | ||||
public function __construct(IL10N $l10n) { | |||||
$this->l10n = $l10n; | |||||
public function __construct( | |||||
protected IL10N $l10n, | |||||
) { | |||||
} | } | ||||
/** | /** |
use OCP\IL10N; | use OCP\IL10N; | ||||
class BundleFetcher { | class BundleFetcher { | ||||
private IL10N $l10n; | |||||
public function __construct(IL10N $l10n) { | |||||
$this->l10n = $l10n; | |||||
public function __construct | |||||
( | |||||
private IL10N $l10n, | |||||
) { | |||||
} | } | ||||
/** | /** |
use Psr\Log\LoggerInterface; | use Psr\Log\LoggerInterface; | ||||
class AppFetcher extends Fetcher { | class AppFetcher extends Fetcher { | ||||
/** @var CompareVersion */ | |||||
private $compareVersion; | |||||
/** @var IRegistry */ | /** @var IRegistry */ | ||||
protected $registry; | |||||
protected IRegistry $registry; | |||||
/** @var bool */ | /** @var bool */ | ||||
private $ignoreMaxVersion; | private $ignoreMaxVersion; | ||||
$registry | $registry | ||||
); | ); | ||||
$this->compareVersion = $compareVersion; | |||||
$this->registry = $registry; | $this->registry = $registry; | ||||
$this->fileName = 'apps.json'; | $this->fileName = 'apps.json'; |
use Psr\Log\LoggerInterface; | use Psr\Log\LoggerInterface; | ||||
class CategoryFetcher extends Fetcher { | class CategoryFetcher extends Fetcher { | ||||
public function __construct(Factory $appDataFactory, | |||||
public function __construct( | |||||
Factory $appDataFactory, | |||||
IClientService $clientService, | IClientService $clientService, | ||||
ITimeFactory $timeFactory, | ITimeFactory $timeFactory, | ||||
IConfig $config, | IConfig $config, | ||||
LoggerInterface $logger, | LoggerInterface $logger, | ||||
IRegistry $registry) { | |||||
IRegistry $registry, | |||||
) { | |||||
parent::__construct( | parent::__construct( | ||||
$appDataFactory, | $appDataFactory, | ||||
$clientService, | $clientService, |
/** @var IAppData */ | /** @var IAppData */ | ||||
protected $appData; | protected $appData; | ||||
/** @var IClientService */ | |||||
protected $clientService; | |||||
/** @var ITimeFactory */ | |||||
protected $timeFactory; | |||||
/** @var IConfig */ | |||||
protected $config; | |||||
/** @var LoggerInterface */ | |||||
protected $logger; | |||||
/** @var IRegistry */ | |||||
protected $registry; | |||||
/** @var string */ | /** @var string */ | ||||
protected $fileName; | protected $fileName; | ||||
/** @var ?string */ | /** @var ?string */ | ||||
protected $channel = null; | protected $channel = null; | ||||
public function __construct(Factory $appDataFactory, | |||||
IClientService $clientService, | |||||
ITimeFactory $timeFactory, | |||||
IConfig $config, | |||||
LoggerInterface $logger, | |||||
IRegistry $registry) { | |||||
public function __construct( | |||||
Factory $appDataFactory, | |||||
protected IClientService $clientService, | |||||
protected ITimeFactory $timeFactory, | |||||
protected IConfig $config, | |||||
protected LoggerInterface $logger, | |||||
protected IRegistry $registry, | |||||
) { | |||||
$this->appData = $appDataFactory->get('appstore'); | $this->appData = $appDataFactory->get('appstore'); | ||||
$this->clientService = $clientService; | |||||
$this->timeFactory = $timeFactory; | |||||
$this->config = $config; | |||||
$this->logger = $logger; | |||||
$this->registry = $registry; | |||||
} | } | ||||
/** | /** |
namespace OC\App\AppStore\Version; | namespace OC\App\AppStore\Version; | ||||
class Version { | class Version { | ||||
/** @var string */ | |||||
private $minVersion; | |||||
/** @var string */ | |||||
private $maxVersion; | |||||
/** | /** | ||||
* @param string $minVersion | * @param string $minVersion | ||||
* @param string $maxVersion | * @param string $maxVersion | ||||
*/ | */ | ||||
public function __construct($minVersion, $maxVersion) { | |||||
$this->minVersion = $minVersion; | |||||
$this->maxVersion = $maxVersion; | |||||
public function __construct( | |||||
private string $minVersion, | |||||
private string $maxVersion, | |||||
) { | |||||
} | } | ||||
/** | /** |
use OCP\IL10N; | use OCP\IL10N; | ||||
class DependencyAnalyzer { | class DependencyAnalyzer { | ||||
/** @var Platform */ | |||||
private $platform; | |||||
/** @var \OCP\IL10N */ | |||||
private $l; | |||||
/** @var array */ | /** @var array */ | ||||
private $appInfo; | private $appInfo; | ||||
* @param Platform $platform | * @param Platform $platform | ||||
* @param \OCP\IL10N $l | * @param \OCP\IL10N $l | ||||
*/ | */ | ||||
public function __construct(Platform $platform, IL10N $l) { | |||||
$this->platform = $platform; | |||||
$this->l = $l; | |||||
public function __construct( | |||||
private Platform $platform, | |||||
private IL10N $l, | |||||
) { | |||||
} | } | ||||
/** | /** |
use function simplexml_load_string; | use function simplexml_load_string; | ||||
class InfoParser { | class InfoParser { | ||||
/** @var \OCP\ICache|null */ | |||||
private $cache; | |||||
/** | /** | ||||
* @param ICache|null $cache | * @param ICache|null $cache | ||||
*/ | */ | ||||
public function __construct(ICache $cache = null) { | |||||
$this->cache = $cache; | |||||
public function __construct( | |||||
private ?ICache $cache = null, | |||||
) { | |||||
} | } | ||||
/** | /** |
* @package OC\App | * @package OC\App | ||||
*/ | */ | ||||
class Platform { | class Platform { | ||||
private IConfig $config; | |||||
public function __construct(IConfig $config) { | |||||
$this->config = $config; | |||||
public function __construct( | |||||
private IConfig $config, | |||||
) { | |||||
} | } | ||||
public function getPhpVersion(): string { | public function getPhpVersion(): string { |