News Feed
Sections




News Archive
Looking for more information on how to do PHP the right way? Check out PHP: The Right Way

Fabien Potencier's Blog:
Symfony Service Container Using XML or YAML to describe Services
April 09, 2009 @ 12:06:22

Fabien Potencier has posted the most recent article in his "Symfony Service Container" series, a look at using XML/YAML to describe services.

Today, with the help of service loaders and dumpers, you will learn how to use XML or YAML to describe your services. The Symfony Dependency Injection component provides helper classes that load services using "loader objects". By default, the component comes with two of them: sfServiceContainerLoaderFileXml to load XML files, and sfServiceContainerLoaderFileYaml to load YAML files.

He reviews the "dumper objects" - tools used to take a service container and push it out into normal PHP code - and how you can use them to dump the Service Container's information out to the XML and YAML formats. Once you have this, it can be loaded back at any time via the two loaders mentioned above. There's plenty of code examples included for these and other more detailed examples.

1 comment voice your opinion now!
service container symfony xml yaml describe tutorial


blog comments powered by Disqus

Similar Posts

Laravel News: Debug Your App with the Laravel Debugbar

Aaron Pollock: Setting up a PHP development environment on a VPS

Raphael Stolt's Blog: Setting up Zend Framework applications with Phing

MaltBlue.com: Zend Form Mastery with Zend_Config - Part 2, Core Form Configuration

Chad Lung's Blog: Install Lighttpd, PHP and MySQL on Ubuntu 10.10


Community Events

Don't see your event here?
Let us know!


framework introduction threedevsandamaybe community interview opinion language laravel development voicesoftheelephpant library release extension series feature wordpress laravel5 podcast unittest api

All content copyright, 2015 PHPDeveloper.org :: info@phpdeveloper.org - Powered by the Solar PHP Framework