aboutsummaryrefslogtreecommitdiffstats
path: root/phpBB/config
diff options
context:
space:
mode:
authorIgor Wiedler <igor@wiedler.ch>2012-03-31 04:06:52 +0200
committerIgor Wiedler <igor@wiedler.ch>2012-03-31 19:25:01 +0200
commit8e2cbe39cdd7672638dbc0d6a0f65a7365db0d91 (patch)
treed063169d4dad8abf34f61120e7a1ba13234d6acc /phpBB/config
parent7e2f16aafa47f8db51a12a293b0616cb75b4d12f (diff)
downloadforums-8e2cbe39cdd7672638dbc0d6a0f65a7365db0d91.tar
forums-8e2cbe39cdd7672638dbc0d6a0f65a7365db0d91.tar.gz
forums-8e2cbe39cdd7672638dbc0d6a0f65a7365db0d91.tar.bz2
forums-8e2cbe39cdd7672638dbc0d6a0f65a7365db0d91.tar.xz
forums-8e2cbe39cdd7672638dbc0d6a0f65a7365db0d91.zip
[feature/dic] Convert common.php to Symfony2 DependencyInjection component
PHPBB3-10739
Diffstat (limited to 'phpBB/config')
-rw-r--r--phpBB/config/parameters.yml11
-rw-r--r--phpBB/config/services.yml87
2 files changed, 98 insertions, 0 deletions
diff --git a/phpBB/config/parameters.yml b/phpBB/config/parameters.yml
new file mode 100644
index 0000000000..8a90c8e99d
--- /dev/null
+++ b/phpBB/config/parameters.yml
@@ -0,0 +1,11 @@
+parameters:
+ cache.acm_type: file
+ dbal.driver: dbal_mysqli
+ dbal.dbhost:
+ dbal.dbuser: root
+ dbal.dbpasswd:
+ dbal.dbname: phpbb_dev
+ dbal.dbport:
+ dbal.new_link: false
+ tables.config: phpbb_config
+ tables.ext: phpbb_ext
diff --git a/phpBB/config/services.yml b/phpBB/config/services.yml
new file mode 100644
index 0000000000..2bf8478f82
--- /dev/null
+++ b/phpBB/config/services.yml
@@ -0,0 +1,87 @@
+services:
+ cache_factory:
+ class: phpbb_cache_factory
+ arguments:
+ - %cache.acm_type%
+
+ cache:
+ class: phpbb_cache_service
+ factory_service: cache_factory
+ factory_method: get_service
+
+ cache.driver:
+ class: phpbb_cache_driver_interface
+ factory_service: cache
+ factory_method: get_driver
+
+ dispatcher:
+ class: phpbb_event_dispatcher
+
+ request:
+ class: phpbb_request
+
+ user:
+ class: phpbb_user
+
+ auth:
+ class: phpbb_auth
+
+ dbal.conn:
+ class: %dbal.driver%
+ calls:
+ - [sql_connect, [%dbal.dbhost%, %dbal.dbuser%, %dbal.dbpasswd%, %dbal.dbname%, %dbal.dbport%, false, %dbal.new_link%]]
+
+ config:
+ class: phpbb_config_db
+ arguments:
+ - @dbal.conn
+ - @cache.driver
+ - %tables.config%
+
+ ext.manager:
+ class: phpbb_extension_manager
+ arguments:
+ - @dbal.conn
+ - %tables.ext%
+ - %core.root_path%
+ - .%core.php_ext%
+ - @cache.driver
+
+ style.resource_locator:
+ class: phpbb_style_resource_locator
+
+ style.path_provider_ext:
+ class: phpbb_style_extension_path_provider
+ arguments:
+ - @ext.manager
+ - @style.path_provider
+
+ style.path_provider:
+ class: phpbb_style_path_provider
+
+ template:
+ class: phpbb_style_template
+ arguments:
+ - %core.root_path%
+ - %core.php_ext%
+ - @config
+ - @user
+ - @style.resource_locator
+ - @style.path_provider_ext
+
+ style:
+ class: phpbb_style
+ arguments:
+ - %core.root_path%
+ - %core.php_ext%
+ - @config
+ - @user
+ - @style.resource_locator
+ - @style.path_provider_ext
+ - @template
+
+ event.subscriber_loader:
+ class: phpbb_event_extension_subscriber_loader
+ arguments:
+ - @dispatcher
+ - @ext.manager