mirror of
https://github.com/phpbb/phpbb.git
synced 2025-06-10 13:28:55 +00:00
[ticket/15287] Add services
PHPBB3-15287
This commit is contained in:
parent
95ebd5d894
commit
440ef369ca
3 changed files with 74 additions and 0 deletions
|
@ -25,6 +25,7 @@ imports:
|
||||||
- { resource: services_profilefield.yml }
|
- { resource: services_profilefield.yml }
|
||||||
- { resource: services_report.yml }
|
- { resource: services_report.yml }
|
||||||
- { resource: services_routing.yml }
|
- { resource: services_routing.yml }
|
||||||
|
- { resource: services_storage.yml }
|
||||||
- { resource: services_text_formatter.yml }
|
- { resource: services_text_formatter.yml }
|
||||||
- { resource: services_text_reparser.yml }
|
- { resource: services_text_reparser.yml }
|
||||||
- { resource: services_twig.yml }
|
- { resource: services_twig.yml }
|
||||||
|
|
|
@ -16,6 +16,17 @@ services:
|
||||||
- '@mimetype.guesser'
|
- '@mimetype.guesser'
|
||||||
- '@plupload'
|
- '@plupload'
|
||||||
|
|
||||||
|
files.filespec_storage:
|
||||||
|
class: phpbb\files\filespec_storage
|
||||||
|
shared: false
|
||||||
|
arguments:
|
||||||
|
- '@language'
|
||||||
|
- '@php_ini'
|
||||||
|
- '@upload_imagesize'
|
||||||
|
- '%core.root_path%'
|
||||||
|
- '@mimetype.guesser'
|
||||||
|
- '@plupload'
|
||||||
|
|
||||||
files.upload:
|
files.upload:
|
||||||
class: phpbb\files\upload
|
class: phpbb\files\upload
|
||||||
shared: false
|
shared: false
|
||||||
|
@ -36,6 +47,16 @@ services:
|
||||||
- '@plupload'
|
- '@plupload'
|
||||||
- '@request'
|
- '@request'
|
||||||
|
|
||||||
|
files.types.form_storage:
|
||||||
|
class: phpbb\files\types\form_storage
|
||||||
|
shared: false
|
||||||
|
arguments:
|
||||||
|
- '@files.factory'
|
||||||
|
- '@language'
|
||||||
|
- '@php_ini'
|
||||||
|
- '@plupload'
|
||||||
|
- '@request'
|
||||||
|
|
||||||
files.types.local:
|
files.types.local:
|
||||||
class: phpbb\files\types\local
|
class: phpbb\files\types\local
|
||||||
shared: false
|
shared: false
|
||||||
|
@ -55,3 +76,14 @@ services:
|
||||||
- '@php_ini'
|
- '@php_ini'
|
||||||
- '@request'
|
- '@request'
|
||||||
- '%core.root_path%'
|
- '%core.root_path%'
|
||||||
|
|
||||||
|
files.types.remote_storage:
|
||||||
|
class: phpbb\files\types\remote_storage
|
||||||
|
shared: false
|
||||||
|
arguments:
|
||||||
|
- '@config'
|
||||||
|
- '@files.factory'
|
||||||
|
- '@language'
|
||||||
|
- '@php_ini'
|
||||||
|
- '@request'
|
||||||
|
- '%core.root_path%'
|
||||||
|
|
41
phpBB/config/default/container/services_storage.yml
Normal file
41
phpBB/config/default/container/services_storage.yml
Normal file
|
@ -0,0 +1,41 @@
|
||||||
|
services:
|
||||||
|
# Factory
|
||||||
|
storage.adapter.factory:
|
||||||
|
class: phpbb\storage\adapter_factory
|
||||||
|
arguments:
|
||||||
|
- '@config'
|
||||||
|
- '@service_container'
|
||||||
|
- '@storage.adapter_collection'
|
||||||
|
- '@storage.provider_collection'
|
||||||
|
|
||||||
|
# Collections
|
||||||
|
storage.adapter_collection:
|
||||||
|
class: phpbb\di\service_collection
|
||||||
|
arguments:
|
||||||
|
- '@service_container'
|
||||||
|
tags:
|
||||||
|
- { name: service_collection, tag: storage.adapter, class_name_aware: true }
|
||||||
|
|
||||||
|
storage.provider_collection:
|
||||||
|
class: phpbb\di\service_collection
|
||||||
|
arguments:
|
||||||
|
- '@service_container'
|
||||||
|
tags:
|
||||||
|
- { name: service_collection, tag: storage.provider, class_name_aware: true }
|
||||||
|
|
||||||
|
# Adapters
|
||||||
|
storage.adapter.local:
|
||||||
|
class: phpbb\storage\adapter\local
|
||||||
|
shared: false
|
||||||
|
arguments:
|
||||||
|
- '@filesystem'
|
||||||
|
- '%core.root_path%'
|
||||||
|
tags:
|
||||||
|
- { name: storage.adapter }
|
||||||
|
|
||||||
|
# Providers
|
||||||
|
storage.provider.local:
|
||||||
|
class: phpbb\storage\provider\local
|
||||||
|
arguments:
|
||||||
|
tags:
|
||||||
|
- { name: storage.provider }
|
Loading…
Add table
Reference in a new issue