36 lines
700 B
PHP
36 lines
700 B
PHP
<?php
|
|
/**
|
|
* S3 Client Factory
|
|
* Фабрика для создания S3 клиента
|
|
*
|
|
* @author AI Assistant
|
|
* @date 2025-09-20
|
|
*/
|
|
|
|
class S3ClientFactory {
|
|
|
|
/**
|
|
* Создание S3 клиента
|
|
*
|
|
* @return S3Client Готовый S3 клиент
|
|
*/
|
|
public static function make() {
|
|
$config = require __DIR__ . '/../../crm_extensions/file_storage/config.php';
|
|
|
|
return new S3Client($config['s3']);
|
|
}
|
|
|
|
/**
|
|
* Создание S3StorageService
|
|
*
|
|
* @return S3StorageService Готовый сервис
|
|
*/
|
|
public static function makeService() {
|
|
return new S3StorageService();
|
|
}
|
|
}
|
|
?>
|
|
|
|
|
|
|