Add 'src/BeSimple/SoapBundle/' from commit 'e99f707b105c0a0472260d8d42a5a14a7fb7a211'

git-subtree-dir: src/BeSimple/SoapBundle
git-subtree-mainline: 9a8d23fa23
git-subtree-split: e99f707b10
This commit is contained in:
Francis Besset
2013-07-19 17:00:11 +02:00
94 changed files with 5786 additions and 0 deletions

View File

@ -0,0 +1,36 @@
<?php
/*
* This file is part of the BeSimpleSoapBundle.
*
* (c) Christian Kerl <christian-kerl@web.de>
*
* This source file is subject to the MIT license that is bundled
* with this source code in the file LICENSE.
*/
namespace BeSimple\SoapBundle\DependencyInjection\Compiler;
use Symfony\Component\DependencyInjection\Reference;
use Symfony\Component\DependencyInjection\ContainerBuilder;
use Symfony\Component\DependencyInjection\Compiler\CompilerPassInterface;
/**
* Adds tagged besimple.soap.converter services to besimple.soap.converter.repository service
*
* @author Christian Kerl <christian-kerl@web.de>
*/
class TypeConverterPass implements CompilerPassInterface
{
public function process(ContainerBuilder $container)
{
if (false === $container->hasDefinition('besimple.soap.converter.collection')) {
return;
}
$definition = $container->getDefinition('besimple.soap.converter.collection');
foreach ($container->findTaggedServiceIds('besimple.soap.converter') as $id => $attributes) {
$definition->addMethodCall('add', array(new Reference($id)));
}
}
}

View File

@ -0,0 +1,36 @@
<?php
/*
* This file is part of the BeSimpleSoapBundle.
*
* (c) Christian Kerl <christian-kerl@web.de>
*
* This source file is subject to the MIT license that is bundled
* with this source code in the file LICENSE.
*/
namespace BeSimple\SoapBundle\DependencyInjection\Compiler;
use Symfony\Component\DependencyInjection\Reference;
use Symfony\Component\DependencyInjection\ContainerBuilder;
use Symfony\Component\DependencyInjection\Compiler\CompilerPassInterface;
/**
* Adds tagged besimple.soap.definition.loader services to ebservice.definition.resolver service
*
* @author Francis Besset <francis.besset@gmail.com>
*/
class WebServiceResolverPass implements CompilerPassInterface
{
public function process(ContainerBuilder $container)
{
if (false === $container->hasDefinition('besimple.soap.definition.loader.resolver')) {
return;
}
$definition = $container->getDefinition('besimple.soap.definition.loader.resolver');
foreach ($container->findTaggedServiceIds('besimple.soap.definition.loader') as $id => $attributes) {
$definition->addMethodCall('addLoader', array(new Reference($id)));
}
}
}