fixed CS (mainly method signatures)
This commit is contained in:
parent
fd1d5e8c10
commit
03d22b74ec
@ -26,7 +26,7 @@ use Symfony\Component\EventDispatcher\EventSubscriberInterface;
|
||||
*/
|
||||
class MergeCollectionListener implements EventSubscriberInterface
|
||||
{
|
||||
static public function getSubscribedEvents()
|
||||
public static function getSubscribedEvents()
|
||||
{
|
||||
return array(FormEvents::BIND_NORM_DATA => 'onBindNormData');
|
||||
}
|
||||
|
@ -26,7 +26,7 @@ interface RegistryInterface
|
||||
*
|
||||
* @return string The default connection name
|
||||
*/
|
||||
function getDefaultConnectionName();
|
||||
public function getDefaultConnectionName();
|
||||
|
||||
/**
|
||||
* Gets the named connection.
|
||||
@ -35,28 +35,28 @@ interface RegistryInterface
|
||||
*
|
||||
* @return Connection
|
||||
*/
|
||||
function getConnection($name = null);
|
||||
public function getConnection($name = null);
|
||||
|
||||
/**
|
||||
* Gets an array of all registered connections
|
||||
*
|
||||
* @return array An array of Connection instances
|
||||
*/
|
||||
function getConnections();
|
||||
public function getConnections();
|
||||
|
||||
/**
|
||||
* Gets all connection names.
|
||||
*
|
||||
* @return array An array of connection names
|
||||
*/
|
||||
function getConnectionNames();
|
||||
public function getConnectionNames();
|
||||
|
||||
/**
|
||||
* Gets the default entity manager name.
|
||||
*
|
||||
* @return string The default entity manager name
|
||||
*/
|
||||
function getDefaultEntityManagerName();
|
||||
public function getDefaultEntityManagerName();
|
||||
|
||||
/**
|
||||
* Gets a named entity manager.
|
||||
@ -65,14 +65,14 @@ interface RegistryInterface
|
||||
*
|
||||
* @return EntityManager
|
||||
*/
|
||||
function getEntityManager($name = null);
|
||||
public function getEntityManager($name = null);
|
||||
|
||||
/**
|
||||
* Gets an array of all registered entity managers
|
||||
*
|
||||
* @return array An array of EntityManager instances
|
||||
*/
|
||||
function getEntityManagers();
|
||||
public function getEntityManagers();
|
||||
|
||||
/**
|
||||
* Resets a named entity manager.
|
||||
@ -91,7 +91,7 @@ interface RegistryInterface
|
||||
*
|
||||
* @return EntityManager
|
||||
*/
|
||||
function resetEntityManager($name = null);
|
||||
public function resetEntityManager($name = null);
|
||||
|
||||
/**
|
||||
* Resolves a registered namespace alias to the full namespace.
|
||||
@ -104,14 +104,14 @@ interface RegistryInterface
|
||||
*
|
||||
* @see Configuration::getEntityNamespace
|
||||
*/
|
||||
function getEntityNamespace($alias);
|
||||
public function getEntityNamespace($alias);
|
||||
|
||||
/**
|
||||
* Gets all connection names.
|
||||
*
|
||||
* @return array An array of connection names
|
||||
*/
|
||||
function getEntityManagerNames();
|
||||
public function getEntityManagerNames();
|
||||
|
||||
/**
|
||||
* Gets the EntityRepository for an entity.
|
||||
@ -121,7 +121,7 @@ interface RegistryInterface
|
||||
*
|
||||
* @return Doctrine\ORM\EntityRepository
|
||||
*/
|
||||
function getRepository($entityName, $entityManagerName = null);
|
||||
public function getRepository($entityName, $entityManagerName = null);
|
||||
|
||||
/**
|
||||
* Gets the entity manager associated with a given class.
|
||||
@ -130,5 +130,5 @@ interface RegistryInterface
|
||||
*
|
||||
* @return EntityManager|null
|
||||
*/
|
||||
function getEntityManagerForClass($class);
|
||||
public function getEntityManagerForClass($class);
|
||||
}
|
||||
|
@ -50,7 +50,6 @@ EOT
|
||||
return parent::execute($input, $output);
|
||||
}
|
||||
|
||||
|
||||
protected function getExporter($toType, $destPath)
|
||||
{
|
||||
$exporter = parent::getExporter($toType, $destPath);
|
||||
|
@ -29,7 +29,7 @@ abstract class DoctrineCommandHelper
|
||||
* @param Application $application
|
||||
* @param string $emName
|
||||
*/
|
||||
static public function setApplicationEntityManager(Application $application, $emName)
|
||||
public static function setApplicationEntityManager(Application $application, $emName)
|
||||
{
|
||||
$em = $application->getKernel()->getContainer()->get('doctrine')->getEntityManager($emName);
|
||||
$helperSet = $application->getHelperSet();
|
||||
@ -37,7 +37,7 @@ abstract class DoctrineCommandHelper
|
||||
$helperSet->set(new EntityManagerHelper($em), 'em');
|
||||
}
|
||||
|
||||
static public function setApplicationConnection(Application $application, $connName)
|
||||
public static function setApplicationConnection(Application $application, $connName)
|
||||
{
|
||||
$connection = $application->getKernel()->getContainer()->get('doctrine')->getConnection($connName);
|
||||
$helperSet = $application->getHelperSet();
|
||||
|
@ -13,7 +13,7 @@ namespace Symfony\Bundle\DoctrineBundle\Tests\DependencyInjection;
|
||||
|
||||
class XMLSchemaTest extends \PHPUnit_Framework_TestCase
|
||||
{
|
||||
static public function dataValidateSchemaFiles()
|
||||
public static function dataValidateSchemaFiles()
|
||||
{
|
||||
$schemaFiles = array();
|
||||
$di = new \DirectoryIterator(__DIR__."/Fixtures/config/xml");
|
||||
@ -35,7 +35,6 @@ class XMLSchemaTest extends \PHPUnit_Framework_TestCase
|
||||
$dom = new \DOMDocument('1.0', 'UTF-8');
|
||||
$dom->load($file);
|
||||
|
||||
|
||||
$dbalElements = $dom->getElementsByTagNameNS("http://symfony.com/schema/dic/doctrine", "config");
|
||||
if ($dbalElements->length) {
|
||||
$dbalDom = new \DOMDocument('1.0', 'UTF-8');
|
||||
|
@ -11,7 +11,6 @@
|
||||
|
||||
namespace Symfony\Bundle\FrameworkBundle\CacheWarmer;
|
||||
|
||||
|
||||
/**
|
||||
* Interface for finding all the templates.
|
||||
*
|
||||
@ -24,5 +23,5 @@ interface TemplateFinderInterface
|
||||
*
|
||||
* @return array An array of templates of type TemplateReferenceInterface
|
||||
*/
|
||||
function findAllTemplates();
|
||||
public function findAllTemplates();
|
||||
}
|
||||
|
@ -24,7 +24,7 @@ class CompilerDebugDumpPass implements CompilerPassInterface
|
||||
$cache->write(implode("\n", $container->getCompiler()->getLog()));
|
||||
}
|
||||
|
||||
static public function getCompilerLogFilename(ContainerInterface $container)
|
||||
public static function getCompilerLogFilename(ContainerInterface $container)
|
||||
{
|
||||
$class = $container->getParameter('kernel.container_class');
|
||||
|
||||
|
@ -4,4 +4,4 @@
|
||||
<?php echo $view['form']->renderBlock('field_errors'); ?>
|
||||
</td>
|
||||
</tr>
|
||||
<?php endif; ?>
|
||||
<?php endif;
|
||||
|
@ -2,4 +2,3 @@
|
||||
<?php echo $view['form']->renderBlock('field_rows') ?>
|
||||
<?php echo $view['form']->rest($form) ?>
|
||||
</table>
|
||||
|
||||
|
@ -3,4 +3,3 @@
|
||||
<?php echo $view['form']->widget($form) ?>
|
||||
</td>
|
||||
</tr>
|
||||
|
||||
|
@ -30,5 +30,5 @@ interface EngineInterface extends BaseEngineInterface
|
||||
*
|
||||
* @return Response A Response instance
|
||||
*/
|
||||
function renderResponse($view, array $parameters = array(), Response $response = null);
|
||||
public function renderResponse($view, array $parameters = array(), Response $response = null);
|
||||
}
|
||||
|
@ -222,7 +222,7 @@ class CodeHelper extends Helper
|
||||
return 'code';
|
||||
}
|
||||
|
||||
static protected function fixCodeMarkup($line)
|
||||
protected static function fixCodeMarkup($line)
|
||||
{
|
||||
// </span> ending tag from previous line
|
||||
$opening = strpos($line, '<span');
|
||||
|
@ -22,8 +22,8 @@ use Symfony\Component\HttpKernel\HttpKernelInterface;
|
||||
*/
|
||||
abstract class WebTestCase extends \PHPUnit_Framework_TestCase
|
||||
{
|
||||
static protected $class;
|
||||
static protected $kernel;
|
||||
protected static $class;
|
||||
protected static $kernel;
|
||||
|
||||
/**
|
||||
* Creates a Client.
|
||||
@ -33,7 +33,7 @@ abstract class WebTestCase extends \PHPUnit_Framework_TestCase
|
||||
*
|
||||
* @return Client A Client instance
|
||||
*/
|
||||
static protected function createClient(array $options = array(), array $server = array())
|
||||
protected static function createClient(array $options = array(), array $server = array())
|
||||
{
|
||||
static::$kernel = static::createKernel($options);
|
||||
static::$kernel->boot();
|
||||
@ -52,7 +52,7 @@ abstract class WebTestCase extends \PHPUnit_Framework_TestCase
|
||||
*
|
||||
* @return string The directory where phpunit.xml(.dist) is stored
|
||||
*/
|
||||
static protected function getPhpUnitXmlDir()
|
||||
protected static function getPhpUnitXmlDir()
|
||||
{
|
||||
if (!isset($_SERVER['argv']) || false === strpos($_SERVER['argv'][0], 'phpunit')) {
|
||||
throw new \RuntimeException('You must override the WebTestCase::createKernel() method.');
|
||||
@ -85,7 +85,7 @@ abstract class WebTestCase extends \PHPUnit_Framework_TestCase
|
||||
*
|
||||
* @return string The value of the phpunit cli configuration option
|
||||
*/
|
||||
static private function getPhpUnitCliConfigArgument()
|
||||
private static function getPhpUnitCliConfigArgument()
|
||||
{
|
||||
$dir = null;
|
||||
$reversedArgs = array_reverse($_SERVER['argv']);
|
||||
@ -110,7 +110,7 @@ abstract class WebTestCase extends \PHPUnit_Framework_TestCase
|
||||
*
|
||||
* @return string The Kernel class name
|
||||
*/
|
||||
static protected function getKernelClass()
|
||||
protected static function getKernelClass()
|
||||
{
|
||||
$dir = isset($_SERVER['KERNEL_DIR']) ? $_SERVER['KERNEL_DIR'] : static::getPhpUnitXmlDir();
|
||||
|
||||
@ -141,7 +141,7 @@ abstract class WebTestCase extends \PHPUnit_Framework_TestCase
|
||||
*
|
||||
* @return HttpKernelInterface A HttpKernelInterface instance
|
||||
*/
|
||||
static protected function createKernel(array $options = array())
|
||||
protected static function createKernel(array $options = array())
|
||||
{
|
||||
if (null === static::$class) {
|
||||
static::$class = static::getKernelClass();
|
||||
|
@ -16,7 +16,6 @@ use Symfony\Bundle\FrameworkBundle\Templating\TemplateNameParser;
|
||||
use Symfony\Bundle\FrameworkBundle\CacheWarmer\TemplateFinder;
|
||||
use Symfony\Bundle\FrameworkBundle\Tests\Fixtures\BaseBundle\BaseBundle;
|
||||
|
||||
|
||||
class TemplateFinderTest extends TestCase
|
||||
{
|
||||
public function testFindAllTemplates()
|
||||
|
@ -203,7 +203,7 @@ class ContainerAwareEventDispatcherTest extends \PHPUnit_Framework_TestCase
|
||||
|
||||
class Service
|
||||
{
|
||||
function onEvent(Event $e)
|
||||
public function onEvent(Event $e)
|
||||
{
|
||||
}
|
||||
}
|
||||
|
@ -58,7 +58,6 @@ class RedirectControllerTest extends TestCase
|
||||
|
||||
$container = $this->getMock('Symfony\Component\DependencyInjection\ContainerInterface');
|
||||
|
||||
|
||||
$container
|
||||
->expects($this->at(0))
|
||||
->method('get')
|
||||
|
@ -42,9 +42,9 @@ class TraceableEventDispatcherTest extends TestCase
|
||||
|
||||
class StaticClassFixture
|
||||
{
|
||||
static public $called = false;
|
||||
public static $called = false;
|
||||
|
||||
static public function staticListener($event)
|
||||
public static function staticListener($event)
|
||||
{
|
||||
self::$called = true;
|
||||
}
|
||||
|
@ -17,4 +17,3 @@ session_setflash:
|
||||
session_showflash:
|
||||
pattern: /session_showflash
|
||||
defaults: { _controller: TestBundle:Session:showFlash}
|
||||
|
||||
|
@ -17,7 +17,7 @@ use Symfony\Component\HttpKernel\Kernel;
|
||||
|
||||
class WebTestCase extends BaseWebTestCase
|
||||
{
|
||||
static public function assertRedirect($response, $location)
|
||||
public static function assertRedirect($response, $location)
|
||||
{
|
||||
self::assertTrue($response->isRedirect(), 'Response is not a redirect, got status code: '.$response->getStatusCode());
|
||||
self::assertEquals('http://localhost'.$location, $response->headers->get('Location'));
|
||||
@ -42,14 +42,14 @@ class WebTestCase extends BaseWebTestCase
|
||||
$fs->remove($dir);
|
||||
}
|
||||
|
||||
static protected function getKernelClass()
|
||||
protected static function getKernelClass()
|
||||
{
|
||||
require_once __DIR__.'/app/AppKernel.php';
|
||||
|
||||
return 'Symfony\Bundle\FrameworkBundle\Tests\Functional\AppKernel';
|
||||
}
|
||||
|
||||
static protected function createKernel(array $options = array())
|
||||
protected static function createKernel(array $options = array())
|
||||
{
|
||||
$class = self::getKernelClass();
|
||||
|
||||
|
@ -1,3 +1,2 @@
|
||||
imports:
|
||||
- { resource: ./../config/default.yml }
|
||||
|
||||
|
@ -17,7 +17,7 @@ class CodeHelperTest extends \PHPUnit_Framework_TestCase
|
||||
{
|
||||
protected static $helper;
|
||||
|
||||
static public function setUpBeforeClass()
|
||||
public static function setUpBeforeClass()
|
||||
{
|
||||
self::$helper = new CodeHelper('txmt://open?url=file://%f&line=%l', '/root', 'UTF-8');
|
||||
}
|
||||
|
@ -85,14 +85,14 @@ class FormHelperDivLayoutTest extends AbstractDivLayoutTest
|
||||
$this->helper->setTheme($view, $themes);
|
||||
}
|
||||
|
||||
static public function themeBlockInheritanceProvider()
|
||||
public static function themeBlockInheritanceProvider()
|
||||
{
|
||||
return array(
|
||||
array(array('TestBundle:Parent'))
|
||||
);
|
||||
}
|
||||
|
||||
static public function themeInheritanceProvider()
|
||||
public static function themeInheritanceProvider()
|
||||
{
|
||||
return array(
|
||||
array(array('TestBundle:Parent'), array('TestBundle:Child'))
|
||||
|
@ -80,7 +80,7 @@ abstract class AbstractFactory implements SecurityFactoryInterface
|
||||
}
|
||||
}
|
||||
|
||||
public final function addOption($name, $default = null)
|
||||
final public function addOption($name, $default = null)
|
||||
{
|
||||
$this->options[$name] = $default;
|
||||
}
|
||||
|
@ -21,11 +21,11 @@ use Symfony\Component\DependencyInjection\ContainerBuilder;
|
||||
*/
|
||||
interface SecurityFactoryInterface
|
||||
{
|
||||
function create(ContainerBuilder $container, $id, $config, $userProvider, $defaultEntryPoint);
|
||||
public function create(ContainerBuilder $container, $id, $config, $userProvider, $defaultEntryPoint);
|
||||
|
||||
function getPosition();
|
||||
public function getPosition();
|
||||
|
||||
function getKey();
|
||||
public function getKey();
|
||||
|
||||
function addConfiguration(NodeDefinition $builder);
|
||||
public function addConfiguration(NodeDefinition $builder);
|
||||
}
|
||||
|
@ -600,7 +600,6 @@ class SecurityExtension extends Extension
|
||||
return $this->factories = $factories;
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* Returns the base path for the XSD files.
|
||||
*
|
||||
@ -616,4 +615,3 @@ class SecurityExtension extends Extension
|
||||
return 'http://symfony.com/schema/dic/security';
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -17,7 +17,7 @@ use Symfony\Component\HttpKernel\Kernel;
|
||||
|
||||
class WebTestCase extends BaseWebTestCase
|
||||
{
|
||||
static public function assertRedirect($response, $location)
|
||||
public static function assertRedirect($response, $location)
|
||||
{
|
||||
self::assertTrue($response->isRedirect(), 'Response is not a redirect, got status code: '.$response->getStatusCode());
|
||||
self::assertEquals('http://localhost'.$location, $response->headers->get('Location'));
|
||||
@ -42,14 +42,14 @@ class WebTestCase extends BaseWebTestCase
|
||||
$fs->remove($dir);
|
||||
}
|
||||
|
||||
static protected function getKernelClass()
|
||||
protected static function getKernelClass()
|
||||
{
|
||||
require_once __DIR__.'/app/AppKernel.php';
|
||||
|
||||
return 'Symfony\Bundle\SecurityBundle\Tests\Functional\AppKernel';
|
||||
}
|
||||
|
||||
static protected function createKernel(array $options = array())
|
||||
protected static function createKernel(array $options = array())
|
||||
{
|
||||
$class = self::getKernelClass();
|
||||
|
||||
|
@ -11,7 +11,6 @@
|
||||
|
||||
namespace Symfony\Bundle\SwiftmailerBundle\Logger;
|
||||
|
||||
|
||||
/**
|
||||
* MessageLogger.
|
||||
*
|
||||
|
@ -28,7 +28,7 @@ class WebProfilerExtensionTest extends TestCase
|
||||
*/
|
||||
private $container;
|
||||
|
||||
static public function assertSaneContainer(Container $container, $message = '')
|
||||
public static function assertSaneContainer(Container $container, $message = '')
|
||||
{
|
||||
$errors = array();
|
||||
foreach ($container->getServiceIds() as $id) {
|
||||
|
@ -117,7 +117,7 @@ class Cookie
|
||||
*
|
||||
* @api
|
||||
*/
|
||||
static public function fromString($cookie, $url = null)
|
||||
public static function fromString($cookie, $url = null)
|
||||
{
|
||||
$parts = explode(';', $cookie);
|
||||
|
||||
|
@ -18,7 +18,7 @@ namespace Symfony\Component\ClassLoader;
|
||||
*/
|
||||
class ClassCollectionLoader
|
||||
{
|
||||
static private $loaded;
|
||||
private static $loaded;
|
||||
|
||||
/**
|
||||
* Loads a list of classes and caches them in one big file.
|
||||
@ -32,7 +32,7 @@ class ClassCollectionLoader
|
||||
*
|
||||
* @throws \InvalidArgumentException When class can't be loaded
|
||||
*/
|
||||
static public function load($classes, $cacheDir, $name, $autoReload, $adaptive = false, $extension = '.php')
|
||||
public static function load($classes, $cacheDir, $name, $autoReload, $adaptive = false, $extension = '.php')
|
||||
{
|
||||
// each $name can only be loaded once per PHP process
|
||||
if (isset(self::$loaded[$name])) {
|
||||
@ -123,7 +123,7 @@ class ClassCollectionLoader
|
||||
*
|
||||
* @return string Namespaces with brackets
|
||||
*/
|
||||
static public function fixNamespaceDeclarations($source)
|
||||
public static function fixNamespaceDeclarations($source)
|
||||
{
|
||||
if (!function_exists('token_get_all')) {
|
||||
return $source;
|
||||
@ -177,7 +177,7 @@ class ClassCollectionLoader
|
||||
*
|
||||
* @throws \RuntimeException when a cache file cannot be written
|
||||
*/
|
||||
static private function writeCacheFile($file, $content)
|
||||
private static function writeCacheFile($file, $content)
|
||||
{
|
||||
$tmpFile = tempnam(dirname($file), basename($file));
|
||||
if (false !== @file_put_contents($tmpFile, $content) && @rename($tmpFile, $file)) {
|
||||
@ -199,7 +199,7 @@ class ClassCollectionLoader
|
||||
*
|
||||
* @return string The PHP string with the comments removed
|
||||
*/
|
||||
static private function stripComments($source)
|
||||
private static function stripComments($source)
|
||||
{
|
||||
if (!function_exists('token_get_all')) {
|
||||
return $source;
|
||||
|
@ -21,7 +21,7 @@ class DebugUniversalClassLoader extends UniversalClassLoader
|
||||
/**
|
||||
* Replaces all regular UniversalClassLoader instances by a DebugUniversalClassLoader ones.
|
||||
*/
|
||||
static public function enable()
|
||||
public static function enable()
|
||||
{
|
||||
if (!is_array($functions = spl_autoload_functions())) {
|
||||
return;
|
||||
|
@ -11,7 +11,6 @@
|
||||
|
||||
namespace Symfony\Component\Config\Definition;
|
||||
|
||||
|
||||
use Symfony\Component\Config\Definition\Exception\InvalidConfigurationException;
|
||||
use Symfony\Component\Config\Definition\Exception\InvalidTypeException;
|
||||
use Symfony\Component\Config\Definition\Exception\UnsetKeyException;
|
||||
|
@ -150,7 +150,7 @@ abstract class BaseNode implements NodeInterface
|
||||
*
|
||||
* @throws ForbiddenOverwriteException
|
||||
*/
|
||||
public final function merge($leftSide, $rightSide)
|
||||
final public function merge($leftSide, $rightSide)
|
||||
{
|
||||
if (!$this->allowOverwrite) {
|
||||
throw new ForbiddenOverwriteException(sprintf(
|
||||
@ -174,7 +174,7 @@ abstract class BaseNode implements NodeInterface
|
||||
*
|
||||
* @return mixed The normalized value.
|
||||
*/
|
||||
public final function normalize($value)
|
||||
final public function normalize($value)
|
||||
{
|
||||
// run custom normalization closures
|
||||
foreach ($this->normalizationClosures as $closure) {
|
||||
@ -202,7 +202,7 @@ abstract class BaseNode implements NodeInterface
|
||||
*
|
||||
* @return mixed The finalized value
|
||||
*/
|
||||
public final function finalize($value)
|
||||
final public function finalize($value)
|
||||
{
|
||||
$this->validateType($value);
|
||||
|
||||
|
@ -214,7 +214,7 @@ class ExprBuilder
|
||||
*
|
||||
* @return array
|
||||
*/
|
||||
static public function buildExpressions(array $expressions)
|
||||
public static function buildExpressions(array $expressions)
|
||||
{
|
||||
foreach ($expressions as $k => $expr) {
|
||||
if ($expr instanceof ExprBuilder) {
|
||||
|
@ -18,9 +18,9 @@ namespace Symfony\Component\Config\Definition\Builder;
|
||||
*/
|
||||
interface ParentNodeDefinitionInterface
|
||||
{
|
||||
function children();
|
||||
public function children();
|
||||
|
||||
function append(NodeDefinition $node);
|
||||
public function append(NodeDefinition $node);
|
||||
|
||||
function setBuilder(NodeBuilder $builder);
|
||||
public function setBuilder(NodeBuilder $builder);
|
||||
}
|
||||
|
@ -23,5 +23,5 @@ interface ConfigurationInterface
|
||||
*
|
||||
* @return \Symfony\Component\Config\Definition\Builder\TreeBuilder The tree builder
|
||||
*/
|
||||
function getConfigTreeBuilder();
|
||||
public function getConfigTreeBuilder();
|
||||
}
|
||||
|
@ -26,28 +26,28 @@ interface NodeInterface
|
||||
*
|
||||
* @return string The name of the node
|
||||
*/
|
||||
function getName();
|
||||
public function getName();
|
||||
|
||||
/**
|
||||
* Returns the path of the node.
|
||||
*
|
||||
* @return string The node path
|
||||
*/
|
||||
function getPath();
|
||||
public function getPath();
|
||||
|
||||
/**
|
||||
* Returns true when the node is required.
|
||||
*
|
||||
* @return Boolean If the node is required
|
||||
*/
|
||||
function isRequired();
|
||||
public function isRequired();
|
||||
|
||||
/**
|
||||
* Returns true when the node has a default value.
|
||||
*
|
||||
* @return Boolean If the node has a default value
|
||||
*/
|
||||
function hasDefaultValue();
|
||||
public function hasDefaultValue();
|
||||
|
||||
/**
|
||||
* Returns the default value of the node.
|
||||
@ -55,7 +55,7 @@ interface NodeInterface
|
||||
* @return mixed The default value
|
||||
* @throws \RuntimeException if the node has no default value
|
||||
*/
|
||||
function getDefaultValue();
|
||||
public function getDefaultValue();
|
||||
|
||||
/**
|
||||
* Normalizes the supplied value.
|
||||
@ -64,7 +64,7 @@ interface NodeInterface
|
||||
*
|
||||
* @return mixed The normalized value
|
||||
*/
|
||||
function normalize($value);
|
||||
public function normalize($value);
|
||||
|
||||
/**
|
||||
* Merges two values together.
|
||||
@ -74,7 +74,7 @@ interface NodeInterface
|
||||
*
|
||||
* @return mixed The merged values
|
||||
*/
|
||||
function merge($leftSide, $rightSide);
|
||||
public function merge($leftSide, $rightSide);
|
||||
|
||||
/**
|
||||
* Finalizes a value.
|
||||
@ -83,5 +83,5 @@ interface NodeInterface
|
||||
*
|
||||
* @return mixed The finalized value
|
||||
*/
|
||||
function finalize($value);
|
||||
public function finalize($value);
|
||||
}
|
||||
|
@ -65,7 +65,7 @@ class Processor
|
||||
*
|
||||
* @return array the config with normalized keys
|
||||
*/
|
||||
static public function normalizeKeys(array $config)
|
||||
public static function normalizeKeys(array $config)
|
||||
{
|
||||
foreach ($config as $key => $value) {
|
||||
if (is_array($value)) {
|
||||
@ -104,7 +104,7 @@ class Processor
|
||||
*
|
||||
* @return array
|
||||
*/
|
||||
static public function normalizeConfig($config, $key, $plural = null)
|
||||
public static function normalizeConfig($config, $key, $plural = null)
|
||||
{
|
||||
if (null === $plural) {
|
||||
$plural = $key.'s';
|
||||
|
@ -23,5 +23,5 @@ interface PrototypeNodeInterface extends NodeInterface
|
||||
*
|
||||
* @param string $name The name of the node
|
||||
*/
|
||||
function setName($name);
|
||||
public function setName($name);
|
||||
}
|
||||
|
@ -27,5 +27,5 @@ interface FileLocatorInterface
|
||||
*
|
||||
* @throws \InvalidArgumentException When file is not found
|
||||
*/
|
||||
function locate($name, $currentPath = null, $first = true);
|
||||
public function locate($name, $currentPath = null, $first = true);
|
||||
}
|
||||
|
@ -22,7 +22,7 @@ use Symfony\Component\Config\Exception\FileLoaderImportCircularReferenceExceptio
|
||||
*/
|
||||
abstract class FileLoader extends Loader
|
||||
{
|
||||
static protected $loading = array();
|
||||
protected static $loading = array();
|
||||
|
||||
protected $locator;
|
||||
|
||||
|
@ -24,7 +24,7 @@ interface LoaderInterface
|
||||
* @param mixed $resource The resource
|
||||
* @param string $type The resource type
|
||||
*/
|
||||
function load($resource, $type = null);
|
||||
public function load($resource, $type = null);
|
||||
|
||||
/**
|
||||
* Returns true if this class supports the given resource.
|
||||
@ -34,20 +34,20 @@ interface LoaderInterface
|
||||
*
|
||||
* @return Boolean true if this class supports the given resource, false otherwise
|
||||
*/
|
||||
function supports($resource, $type = null);
|
||||
public function supports($resource, $type = null);
|
||||
|
||||
/**
|
||||
* Gets the loader resolver.
|
||||
*
|
||||
* @return LoaderResolver A LoaderResolver instance
|
||||
*/
|
||||
function getResolver();
|
||||
public function getResolver();
|
||||
|
||||
/**
|
||||
* Sets the loader resolver.
|
||||
*
|
||||
* @param LoaderResolver $resolver A LoaderResolver instance
|
||||
*/
|
||||
function setResolver(LoaderResolver $resolver);
|
||||
public function setResolver(LoaderResolver $resolver);
|
||||
|
||||
}
|
||||
|
@ -26,5 +26,5 @@ interface LoaderResolverInterface
|
||||
*
|
||||
* @return LoaderInterface A LoaderInterface instance
|
||||
*/
|
||||
function resolve($resource, $type = null);
|
||||
public function resolve($resource, $type = null);
|
||||
}
|
||||
|
@ -23,7 +23,7 @@ interface ResourceInterface
|
||||
*
|
||||
* @return string A string representation of the Resource
|
||||
*/
|
||||
function __toString();
|
||||
public function __toString();
|
||||
|
||||
/**
|
||||
* Returns true if the resource has not been updated since the given timestamp.
|
||||
@ -32,12 +32,12 @@ interface ResourceInterface
|
||||
*
|
||||
* @return Boolean true if the resource has not been updated, false otherwise
|
||||
*/
|
||||
function isFresh($timestamp);
|
||||
public function isFresh($timestamp);
|
||||
|
||||
/**
|
||||
* Returns the resource tied to this Resource.
|
||||
*
|
||||
* @return mixed The resource
|
||||
*/
|
||||
function getResource();
|
||||
public function getResource();
|
||||
}
|
||||
|
@ -596,7 +596,7 @@ class Application
|
||||
*
|
||||
* @return array An array of abbreviations
|
||||
*/
|
||||
static public function getAbbreviations($names)
|
||||
public static function getAbbreviations($names)
|
||||
{
|
||||
$abbrevs = array();
|
||||
foreach ($names as $name) {
|
||||
|
@ -27,7 +27,7 @@ interface OutputFormatterInterface
|
||||
*
|
||||
* @api
|
||||
*/
|
||||
function setDecorated($decorated);
|
||||
public function setDecorated($decorated);
|
||||
|
||||
/**
|
||||
* Gets the decorated flag.
|
||||
@ -36,7 +36,7 @@ interface OutputFormatterInterface
|
||||
*
|
||||
* @api
|
||||
*/
|
||||
function isDecorated();
|
||||
public function isDecorated();
|
||||
|
||||
/**
|
||||
* Sets a new style.
|
||||
@ -46,7 +46,7 @@ interface OutputFormatterInterface
|
||||
*
|
||||
* @api
|
||||
*/
|
||||
function setStyle($name, OutputFormatterStyleInterface $style);
|
||||
public function setStyle($name, OutputFormatterStyleInterface $style);
|
||||
|
||||
/**
|
||||
* Checks if output formatter has style with specified name.
|
||||
@ -57,7 +57,7 @@ interface OutputFormatterInterface
|
||||
*
|
||||
* @api
|
||||
*/
|
||||
function hasStyle($name);
|
||||
public function hasStyle($name);
|
||||
|
||||
/**
|
||||
* Gets style options from style with specified name.
|
||||
@ -68,7 +68,7 @@ interface OutputFormatterInterface
|
||||
*
|
||||
* @api
|
||||
*/
|
||||
function getStyle($name);
|
||||
public function getStyle($name);
|
||||
|
||||
/**
|
||||
* Formats a message according to the given styles.
|
||||
@ -79,5 +79,5 @@ interface OutputFormatterInterface
|
||||
*
|
||||
* @api
|
||||
*/
|
||||
function format($message);
|
||||
public function format($message);
|
||||
}
|
||||
|
@ -20,7 +20,7 @@ namespace Symfony\Component\Console\Formatter;
|
||||
*/
|
||||
class OutputFormatterStyle implements OutputFormatterStyleInterface
|
||||
{
|
||||
static private $availableForegroundColors = array(
|
||||
private static $availableForegroundColors = array(
|
||||
'black' => 30,
|
||||
'red' => 31,
|
||||
'green' => 32,
|
||||
@ -30,7 +30,7 @@ class OutputFormatterStyle implements OutputFormatterStyleInterface
|
||||
'cyan' => 36,
|
||||
'white' => 37
|
||||
);
|
||||
static private $availableBackgroundColors = array(
|
||||
private static $availableBackgroundColors = array(
|
||||
'black' => 40,
|
||||
'red' => 41,
|
||||
'green' => 42,
|
||||
@ -40,7 +40,7 @@ class OutputFormatterStyle implements OutputFormatterStyleInterface
|
||||
'cyan' => 46,
|
||||
'white' => 47
|
||||
);
|
||||
static private $availableOptions = array(
|
||||
private static $availableOptions = array(
|
||||
'bold' => 1,
|
||||
'underscore' => 4,
|
||||
'blink' => 5,
|
||||
|
@ -27,7 +27,7 @@ interface OutputFormatterStyleInterface
|
||||
*
|
||||
* @api
|
||||
*/
|
||||
function setForeground($color = null);
|
||||
public function setForeground($color = null);
|
||||
|
||||
/**
|
||||
* Sets style background color.
|
||||
@ -36,7 +36,7 @@ interface OutputFormatterStyleInterface
|
||||
*
|
||||
* @api
|
||||
*/
|
||||
function setBackground($color = null);
|
||||
public function setBackground($color = null);
|
||||
|
||||
/**
|
||||
* Sets some specific style option.
|
||||
@ -45,21 +45,21 @@ interface OutputFormatterStyleInterface
|
||||
*
|
||||
* @api
|
||||
*/
|
||||
function setOption($option);
|
||||
public function setOption($option);
|
||||
|
||||
/**
|
||||
* Unsets some specific style option.
|
||||
*
|
||||
* @param string $option Theoption name
|
||||
*/
|
||||
function unsetOption($option);
|
||||
public function unsetOption($option);
|
||||
|
||||
/**
|
||||
* Sets multiple style options at once.
|
||||
*
|
||||
* @param array $options
|
||||
*/
|
||||
function setOptions(array $options);
|
||||
public function setOptions(array $options);
|
||||
|
||||
/**
|
||||
* Applies the style to a given text.
|
||||
@ -68,5 +68,5 @@ interface OutputFormatterStyleInterface
|
||||
*
|
||||
* @return string
|
||||
*/
|
||||
function apply($text);
|
||||
public function apply($text);
|
||||
}
|
||||
|
@ -27,7 +27,7 @@ interface HelperInterface
|
||||
*
|
||||
* @api
|
||||
*/
|
||||
function setHelperSet(HelperSet $helperSet = null);
|
||||
public function setHelperSet(HelperSet $helperSet = null);
|
||||
|
||||
/**
|
||||
* Gets the helper set associated with this helper.
|
||||
@ -36,7 +36,7 @@ interface HelperInterface
|
||||
*
|
||||
* @api
|
||||
*/
|
||||
function getHelperSet();
|
||||
public function getHelperSet();
|
||||
|
||||
/**
|
||||
* Returns the canonical name of this helper.
|
||||
@ -45,5 +45,5 @@ interface HelperInterface
|
||||
*
|
||||
* @api
|
||||
*/
|
||||
function getName();
|
||||
public function getName();
|
||||
}
|
||||
|
@ -23,7 +23,7 @@ interface InputInterface
|
||||
*
|
||||
* @return string The value of the first argument or null otherwise
|
||||
*/
|
||||
function getFirstArgument();
|
||||
public function getFirstArgument();
|
||||
|
||||
/**
|
||||
* Returns true if the raw parameters (not parsed) contain a value.
|
||||
@ -35,7 +35,7 @@ interface InputInterface
|
||||
*
|
||||
* @return Boolean true if the value is contained in the raw parameters
|
||||
*/
|
||||
function hasParameterOption($values);
|
||||
public function hasParameterOption($values);
|
||||
|
||||
/**
|
||||
* Returns the value of a raw option (not parsed).
|
||||
@ -48,14 +48,14 @@ interface InputInterface
|
||||
*
|
||||
* @return mixed The option value
|
||||
*/
|
||||
function getParameterOption($values, $default = false);
|
||||
public function getParameterOption($values, $default = false);
|
||||
|
||||
/**
|
||||
* Binds the current Input instance with the given arguments and options.
|
||||
*
|
||||
* @param InputDefinition $definition A InputDefinition instance
|
||||
*/
|
||||
function bind(InputDefinition $definition);
|
||||
public function bind(InputDefinition $definition);
|
||||
|
||||
/**
|
||||
* Validates if arguments given are correct.
|
||||
@ -64,14 +64,14 @@ interface InputInterface
|
||||
*
|
||||
* @throws \RuntimeException
|
||||
*/
|
||||
function validate();
|
||||
public function validate();
|
||||
|
||||
/**
|
||||
* Returns all the given arguments merged with the default values.
|
||||
*
|
||||
* @return array
|
||||
*/
|
||||
function getArguments();
|
||||
public function getArguments();
|
||||
|
||||
/**
|
||||
* Gets argument by name.
|
||||
@ -80,14 +80,14 @@ interface InputInterface
|
||||
*
|
||||
* @return mixed
|
||||
*/
|
||||
function getArgument($name);
|
||||
public function getArgument($name);
|
||||
|
||||
/**
|
||||
* Returns all the given options merged with the default values.
|
||||
*
|
||||
* @return array
|
||||
*/
|
||||
function getOptions();
|
||||
public function getOptions();
|
||||
|
||||
/**
|
||||
* Gets an option by name.
|
||||
@ -96,12 +96,12 @@ interface InputInterface
|
||||
*
|
||||
* @return mixed
|
||||
*/
|
||||
function getOption($name);
|
||||
public function getOption($name);
|
||||
|
||||
/**
|
||||
* Is this input means interactive?
|
||||
*
|
||||
* @return Boolean
|
||||
*/
|
||||
function isInteractive();
|
||||
public function isInteractive();
|
||||
}
|
||||
|
@ -41,7 +41,7 @@ interface OutputInterface
|
||||
*
|
||||
* @api
|
||||
*/
|
||||
function write($messages, $newline = false, $type = 0);
|
||||
public function write($messages, $newline = false, $type = 0);
|
||||
|
||||
/**
|
||||
* Writes a message to the output and adds a newline at the end.
|
||||
@ -51,7 +51,7 @@ interface OutputInterface
|
||||
*
|
||||
* @api
|
||||
*/
|
||||
function writeln($messages, $type = 0);
|
||||
public function writeln($messages, $type = 0);
|
||||
|
||||
/**
|
||||
* Sets the verbosity of the output.
|
||||
@ -60,7 +60,7 @@ interface OutputInterface
|
||||
*
|
||||
* @api
|
||||
*/
|
||||
function setVerbosity($level);
|
||||
public function setVerbosity($level);
|
||||
|
||||
/**
|
||||
* Gets the current verbosity of the output.
|
||||
@ -69,7 +69,7 @@ interface OutputInterface
|
||||
*
|
||||
* @api
|
||||
*/
|
||||
function getVerbosity();
|
||||
public function getVerbosity();
|
||||
|
||||
/**
|
||||
* Sets the decorated flag.
|
||||
@ -78,7 +78,7 @@ interface OutputInterface
|
||||
*
|
||||
* @api
|
||||
*/
|
||||
function setDecorated($decorated);
|
||||
public function setDecorated($decorated);
|
||||
|
||||
/**
|
||||
* Gets the decorated flag.
|
||||
@ -87,7 +87,7 @@ interface OutputInterface
|
||||
*
|
||||
* @api
|
||||
*/
|
||||
function isDecorated();
|
||||
public function isDecorated();
|
||||
|
||||
/**
|
||||
* Sets output formatter.
|
||||
@ -96,7 +96,7 @@ interface OutputInterface
|
||||
*
|
||||
* @api
|
||||
*/
|
||||
function setFormatter(OutputFormatterInterface $formatter);
|
||||
public function setFormatter(OutputFormatterInterface $formatter);
|
||||
|
||||
/**
|
||||
* Returns current output formatter instance.
|
||||
@ -105,5 +105,5 @@ interface OutputInterface
|
||||
*
|
||||
* @api
|
||||
*/
|
||||
function getFormatter();
|
||||
public function getFormatter();
|
||||
}
|
||||
|
@ -42,7 +42,7 @@ class CssSelector
|
||||
*
|
||||
* @api
|
||||
*/
|
||||
static public function toXPath($cssExpr, $prefix = 'descendant-or-self::')
|
||||
public static function toXPath($cssExpr, $prefix = 'descendant-or-self::')
|
||||
{
|
||||
if (is_string($cssExpr)) {
|
||||
if (!$cssExpr) {
|
||||
|
@ -23,7 +23,7 @@ use Symfony\Component\CssSelector\Exception\ParseException;
|
||||
*/
|
||||
class CombinedSelectorNode implements NodeInterface
|
||||
{
|
||||
static protected $methodMapping = array(
|
||||
protected static $methodMapping = array(
|
||||
' ' => 'descendant',
|
||||
'>' => 'child',
|
||||
'+' => 'direct_adjacent',
|
||||
|
@ -24,7 +24,7 @@ use Symfony\Component\CssSelector\XPathExpr;
|
||||
*/
|
||||
class FunctionNode implements NodeInterface
|
||||
{
|
||||
static protected $unsupported = array('target', 'lang', 'enabled', 'disabled');
|
||||
protected static $unsupported = array('target', 'lang', 'enabled', 'disabled');
|
||||
|
||||
protected $selector;
|
||||
protected $type;
|
||||
|
@ -26,12 +26,12 @@ interface NodeInterface
|
||||
*
|
||||
* @return string The string representation
|
||||
*/
|
||||
function __toString();
|
||||
public function __toString();
|
||||
|
||||
/**
|
||||
* @return XPathExpr The XPath expression
|
||||
*
|
||||
* @throws ParseException When unknown operator is found
|
||||
*/
|
||||
function toXpath();
|
||||
public function toXpath();
|
||||
}
|
||||
|
@ -23,7 +23,7 @@ use Symfony\Component\CssSelector\Exception\ParseException;
|
||||
*/
|
||||
class PseudoNode implements NodeInterface
|
||||
{
|
||||
static protected $unsupported = array(
|
||||
protected static $unsupported = array(
|
||||
'indeterminate', 'first-line', 'first-letter',
|
||||
'selection', 'before', 'after', 'link', 'visited',
|
||||
'active', 'focus', 'hover',
|
||||
|
@ -219,7 +219,7 @@ class XPathExpr
|
||||
*
|
||||
* @return string
|
||||
*/
|
||||
static public function xpathLiteral($s)
|
||||
public static function xpathLiteral($s)
|
||||
{
|
||||
if ($s instanceof Node\ElementNode) {
|
||||
// This is probably a symbol that looks like an expression...
|
||||
|
@ -31,5 +31,5 @@ interface CompilerPassInterface
|
||||
*
|
||||
* @api
|
||||
*/
|
||||
function process(ContainerBuilder $container);
|
||||
public function process(ContainerBuilder $container);
|
||||
}
|
||||
|
@ -11,7 +11,6 @@
|
||||
|
||||
namespace Symfony\Component\DependencyInjection\Compiler;
|
||||
|
||||
|
||||
/**
|
||||
* Used to format logging messages during the compilation.
|
||||
*
|
||||
|
@ -24,5 +24,5 @@ interface RepeatablePassInterface extends CompilerPassInterface
|
||||
*
|
||||
* @param RepeatedPass $repeatedPass
|
||||
*/
|
||||
function setRepeatedPass(RepeatedPass $repeatedPass);
|
||||
public function setRepeatedPass(RepeatedPass $repeatedPass);
|
||||
}
|
||||
|
@ -440,7 +440,7 @@ class Container implements ContainerInterface
|
||||
*
|
||||
* @return string The camelized string
|
||||
*/
|
||||
static public function camelize($id)
|
||||
public static function camelize($id)
|
||||
{
|
||||
return preg_replace_callback('/(^|_|\.)+(.)/', function ($match) { return ('.' === $match[1] ? '_' : '').strtoupper($match[2]); }, $id);
|
||||
}
|
||||
@ -452,7 +452,7 @@ class Container implements ContainerInterface
|
||||
*
|
||||
* @return string The underscored string
|
||||
*/
|
||||
static public function underscore($id)
|
||||
public static function underscore($id)
|
||||
{
|
||||
return strtolower(preg_replace(array('/([A-Z]+)([A-Z][a-z])/', '/([a-z\d])([A-Z])/'), array('\\1_\\2', '\\1_\\2'), strtr($id, '_', '.')));
|
||||
}
|
||||
|
@ -27,5 +27,5 @@ interface ContainerAwareInterface
|
||||
*
|
||||
* @api
|
||||
*/
|
||||
function setContainer(ContainerInterface $container = null);
|
||||
public function setContainer(ContainerInterface $container = null);
|
||||
}
|
||||
|
@ -837,7 +837,7 @@ class ContainerBuilder extends Container implements TaggedContainerInterface
|
||||
*
|
||||
* @return array An array of Service conditionals
|
||||
*/
|
||||
static public function getServiceConditionals($value)
|
||||
public static function getServiceConditionals($value)
|
||||
{
|
||||
$services = array();
|
||||
|
||||
|
@ -36,7 +36,7 @@ interface ContainerInterface
|
||||
*
|
||||
* @api
|
||||
*/
|
||||
function set($id, $service, $scope = self::SCOPE_CONTAINER);
|
||||
public function set($id, $service, $scope = self::SCOPE_CONTAINER);
|
||||
|
||||
/**
|
||||
* Gets a service.
|
||||
@ -52,7 +52,7 @@ interface ContainerInterface
|
||||
*
|
||||
* @api
|
||||
*/
|
||||
function get($id, $invalidBehavior = self::EXCEPTION_ON_INVALID_REFERENCE);
|
||||
public function get($id, $invalidBehavior = self::EXCEPTION_ON_INVALID_REFERENCE);
|
||||
|
||||
/**
|
||||
* Returns true if the given service is defined.
|
||||
@ -63,7 +63,7 @@ interface ContainerInterface
|
||||
*
|
||||
* @api
|
||||
*/
|
||||
function has($id);
|
||||
public function has($id);
|
||||
|
||||
/**
|
||||
* Gets a parameter.
|
||||
@ -76,7 +76,7 @@ interface ContainerInterface
|
||||
*
|
||||
* @api
|
||||
*/
|
||||
function getParameter($name);
|
||||
public function getParameter($name);
|
||||
|
||||
/**
|
||||
* Checks if a parameter exists.
|
||||
@ -87,7 +87,7 @@ interface ContainerInterface
|
||||
*
|
||||
* @api
|
||||
*/
|
||||
function hasParameter($name);
|
||||
public function hasParameter($name);
|
||||
|
||||
/**
|
||||
* Sets a parameter.
|
||||
@ -97,7 +97,7 @@ interface ContainerInterface
|
||||
*
|
||||
* @api
|
||||
*/
|
||||
function setParameter($name, $value);
|
||||
public function setParameter($name, $value);
|
||||
|
||||
/**
|
||||
* Enters the given scope
|
||||
@ -108,7 +108,7 @@ interface ContainerInterface
|
||||
*
|
||||
* @api
|
||||
*/
|
||||
function enterScope($name);
|
||||
public function enterScope($name);
|
||||
|
||||
/**
|
||||
* Leaves the current scope, and re-enters the parent scope
|
||||
@ -119,7 +119,7 @@ interface ContainerInterface
|
||||
*
|
||||
* @api
|
||||
*/
|
||||
function leaveScope($name);
|
||||
public function leaveScope($name);
|
||||
|
||||
/**
|
||||
* Adds a scope to the container
|
||||
@ -130,7 +130,7 @@ interface ContainerInterface
|
||||
*
|
||||
* @api
|
||||
*/
|
||||
function addScope(ScopeInterface $scope);
|
||||
public function addScope(ScopeInterface $scope);
|
||||
|
||||
/**
|
||||
* Whether this container has the given scope
|
||||
@ -141,7 +141,7 @@ interface ContainerInterface
|
||||
*
|
||||
* @api
|
||||
*/
|
||||
function hasScope($name);
|
||||
public function hasScope($name);
|
||||
|
||||
/**
|
||||
* Determines whether the given scope is currently active.
|
||||
@ -154,5 +154,5 @@ interface ContainerInterface
|
||||
*
|
||||
* @api
|
||||
*/
|
||||
function isScopeActive($name);
|
||||
public function isScopeActive($name);
|
||||
}
|
||||
|
@ -29,5 +29,5 @@ interface DumperInterface
|
||||
*
|
||||
* @api
|
||||
*/
|
||||
function dump(array $options = array());
|
||||
public function dump(array $options = array());
|
||||
}
|
||||
|
@ -294,7 +294,7 @@ class XmlDumper extends Dumper
|
||||
*
|
||||
* @throws \RuntimeException When trying to dump object or resource
|
||||
*/
|
||||
static public function phpToXml($value)
|
||||
public static function phpToXml($value)
|
||||
{
|
||||
switch (true) {
|
||||
case null === $value:
|
||||
|
@ -32,7 +32,7 @@ interface ExtensionInterface
|
||||
*
|
||||
* @api
|
||||
*/
|
||||
function load(array $config, ContainerBuilder $container);
|
||||
public function load(array $config, ContainerBuilder $container);
|
||||
|
||||
/**
|
||||
* Returns the namespace to be used for this extension (XML namespace).
|
||||
@ -41,7 +41,7 @@ interface ExtensionInterface
|
||||
*
|
||||
* @api
|
||||
*/
|
||||
function getNamespace();
|
||||
public function getNamespace();
|
||||
|
||||
/**
|
||||
* Returns the base path for the XSD files.
|
||||
@ -50,7 +50,7 @@ interface ExtensionInterface
|
||||
*
|
||||
* @api
|
||||
*/
|
||||
function getXsdValidationBasePath();
|
||||
public function getXsdValidationBasePath();
|
||||
|
||||
/**
|
||||
* Returns the recommended alias to use in XML.
|
||||
@ -61,5 +61,5 @@ interface ExtensionInterface
|
||||
*
|
||||
* @api
|
||||
*/
|
||||
function getAlias();
|
||||
public function getAlias();
|
||||
}
|
||||
|
@ -467,7 +467,7 @@ EOF
|
||||
*
|
||||
* @return array A PHP array
|
||||
*/
|
||||
static public function convertDomElementToArray(\DomElement $element)
|
||||
public static function convertDomElementToArray(\DomElement $element)
|
||||
{
|
||||
$empty = true;
|
||||
$config = array();
|
||||
|
@ -27,7 +27,7 @@ interface ParameterBagInterface
|
||||
*
|
||||
* @api
|
||||
*/
|
||||
function clear();
|
||||
public function clear();
|
||||
|
||||
/**
|
||||
* Adds parameters to the service container parameters.
|
||||
@ -36,7 +36,7 @@ interface ParameterBagInterface
|
||||
*
|
||||
* @api
|
||||
*/
|
||||
function add(array $parameters);
|
||||
public function add(array $parameters);
|
||||
|
||||
/**
|
||||
* Gets the service container parameters.
|
||||
@ -45,7 +45,7 @@ interface ParameterBagInterface
|
||||
*
|
||||
* @api
|
||||
*/
|
||||
function all();
|
||||
public function all();
|
||||
|
||||
/**
|
||||
* Gets a service container parameter.
|
||||
@ -58,7 +58,7 @@ interface ParameterBagInterface
|
||||
*
|
||||
* @api
|
||||
*/
|
||||
function get($name);
|
||||
public function get($name);
|
||||
|
||||
/**
|
||||
* Sets a service container parameter.
|
||||
@ -68,7 +68,7 @@ interface ParameterBagInterface
|
||||
*
|
||||
* @api
|
||||
*/
|
||||
function set($name, $value);
|
||||
public function set($name, $value);
|
||||
|
||||
/**
|
||||
* Returns true if a parameter name is defined.
|
||||
@ -79,12 +79,12 @@ interface ParameterBagInterface
|
||||
*
|
||||
* @api
|
||||
*/
|
||||
function has($name);
|
||||
public function has($name);
|
||||
|
||||
/**
|
||||
* Replaces parameter placeholders (%name%) by their values for all parameters.
|
||||
*/
|
||||
function resolve();
|
||||
public function resolve();
|
||||
|
||||
/**
|
||||
* Replaces parameter placeholders (%name%) by their values.
|
||||
@ -93,5 +93,5 @@ interface ParameterBagInterface
|
||||
*
|
||||
* @throws ParameterNotFoundException if a placeholder references a parameter that does not exist
|
||||
*/
|
||||
function resolveValue($value);
|
||||
public function resolveValue($value);
|
||||
}
|
||||
|
@ -23,10 +23,10 @@ interface ScopeInterface
|
||||
/**
|
||||
* @api
|
||||
*/
|
||||
function getName();
|
||||
public function getName();
|
||||
|
||||
/**
|
||||
* @api
|
||||
*/
|
||||
function getParentName();
|
||||
public function getParentName();
|
||||
}
|
||||
|
@ -99,7 +99,7 @@ class SimpleXMLElement extends \SimpleXMLElement
|
||||
*
|
||||
* @return mixed
|
||||
*/
|
||||
static public function phpize($value)
|
||||
public static function phpize($value)
|
||||
{
|
||||
$value = (string) $value;
|
||||
$lowercaseValue = strtolower($value);
|
||||
|
@ -29,5 +29,5 @@ interface TaggedContainerInterface extends ContainerInterface
|
||||
*
|
||||
* @api
|
||||
*/
|
||||
function findTaggedServiceIds($name);
|
||||
public function findTaggedServiceIds($name);
|
||||
}
|
||||
|
@ -643,7 +643,7 @@ class Crawler extends \SplObjectStorage
|
||||
* @return string Converted string
|
||||
*
|
||||
*/
|
||||
static public function xpathLiteral($s)
|
||||
public static function xpathLiteral($s)
|
||||
{
|
||||
if (false === strpos($s, "'")) {
|
||||
return sprintf("'%s'", $s);
|
||||
|
@ -33,7 +33,7 @@ interface EventDispatcherInterface
|
||||
*
|
||||
* @api
|
||||
*/
|
||||
function dispatch($eventName, Event $event = null);
|
||||
public function dispatch($eventName, Event $event = null);
|
||||
|
||||
/**
|
||||
* Adds an event listener that listens on the specified events.
|
||||
@ -45,7 +45,7 @@ interface EventDispatcherInterface
|
||||
*
|
||||
* @api
|
||||
*/
|
||||
function addListener($eventName, $listener, $priority = 0);
|
||||
public function addListener($eventName, $listener, $priority = 0);
|
||||
|
||||
/**
|
||||
* Adds an event subscriber.
|
||||
@ -57,7 +57,7 @@ interface EventDispatcherInterface
|
||||
*
|
||||
* @api
|
||||
*/
|
||||
function addSubscriber(EventSubscriberInterface $subscriber);
|
||||
public function addSubscriber(EventSubscriberInterface $subscriber);
|
||||
|
||||
/**
|
||||
* Removes an event listener from the specified events.
|
||||
@ -65,14 +65,14 @@ interface EventDispatcherInterface
|
||||
* @param string|array $eventName The event(s) to remove a listener from
|
||||
* @param callable $listener The listener to remove
|
||||
*/
|
||||
function removeListener($eventName, $listener);
|
||||
public function removeListener($eventName, $listener);
|
||||
|
||||
/**
|
||||
* Removes an event subscriber.
|
||||
*
|
||||
* @param EventSubscriberInterface $subscriber The subscriber
|
||||
*/
|
||||
function removeSubscriber(EventSubscriberInterface $subscriber);
|
||||
public function removeSubscriber(EventSubscriberInterface $subscriber);
|
||||
|
||||
/**
|
||||
* Gets the listeners of a specific event or all listeners.
|
||||
@ -81,7 +81,7 @@ interface EventDispatcherInterface
|
||||
*
|
||||
* @return array The event listeners for the specified event, or all event listeners by event name
|
||||
*/
|
||||
function getListeners($eventName = null);
|
||||
public function getListeners($eventName = null);
|
||||
|
||||
/**
|
||||
* Checks whether an event has any registered listeners.
|
||||
@ -90,5 +90,5 @@ interface EventDispatcherInterface
|
||||
*
|
||||
* @return Boolean true if the specified event has any listeners, false otherwise
|
||||
*/
|
||||
function hasListeners($eventName = null);
|
||||
public function hasListeners($eventName = null);
|
||||
}
|
||||
|
@ -43,5 +43,5 @@ interface EventSubscriberInterface
|
||||
*
|
||||
* @api
|
||||
*/
|
||||
static function getSubscribedEvents();
|
||||
public static function getSubscribedEvents();
|
||||
}
|
||||
|
@ -45,7 +45,7 @@ class Finder implements \IteratorAggregate
|
||||
private $dates = array();
|
||||
private $iterators = array();
|
||||
|
||||
static private $vcsPatterns = array('.svn', '_svn', 'CVS', '_darcs', '.arch-params', '.monotone', '.bzr', '.git', '.hg');
|
||||
private static $vcsPatterns = array('.svn', '_svn', 'CVS', '_darcs', '.arch-params', '.monotone', '.bzr', '.git', '.hg');
|
||||
|
||||
/**
|
||||
* Constructor.
|
||||
@ -62,7 +62,7 @@ class Finder implements \IteratorAggregate
|
||||
*
|
||||
* @api
|
||||
*/
|
||||
static public function create()
|
||||
public static function create()
|
||||
{
|
||||
return new self();
|
||||
}
|
||||
@ -273,7 +273,7 @@ class Finder implements \IteratorAggregate
|
||||
return $this;
|
||||
}
|
||||
|
||||
static public function addVCSPattern($pattern)
|
||||
public static function addVCSPattern($pattern)
|
||||
{
|
||||
self::$vcsPatterns[] = $pattern;
|
||||
}
|
||||
|
@ -44,7 +44,7 @@ class Glob
|
||||
*
|
||||
* @return string regex The regexp
|
||||
*/
|
||||
static public function toRegex($glob, $strictLeadingDot = true, $strictWildcardSlash = true)
|
||||
public static function toRegex($glob, $strictLeadingDot = true, $strictWildcardSlash = true)
|
||||
{
|
||||
$firstByte = true;
|
||||
$escaping = false;
|
||||
|
@ -13,11 +13,11 @@ namespace Symfony\Component\Form;
|
||||
|
||||
interface DataMapperInterface
|
||||
{
|
||||
function mapDataToForms($data, array $forms);
|
||||
public function mapDataToForms($data, array $forms);
|
||||
|
||||
function mapDataToForm($data, FormInterface $form);
|
||||
public function mapDataToForm($data, FormInterface $form);
|
||||
|
||||
function mapFormsToData(array $forms, &$data);
|
||||
public function mapFormsToData(array $forms, &$data);
|
||||
|
||||
function mapFormToData(FormInterface $form, &$data);
|
||||
public function mapFormToData(FormInterface $form, &$data);
|
||||
}
|
||||
|
@ -46,7 +46,7 @@ interface DataTransformerInterface
|
||||
* @throws UnexpectedTypeException when the argument is not a string
|
||||
* @throws TransformationFailedException when the transformation fails
|
||||
*/
|
||||
function transform($value);
|
||||
public function transform($value);
|
||||
|
||||
/**
|
||||
* Transforms a value from the transformed representation to its original
|
||||
@ -73,5 +73,5 @@ interface DataTransformerInterface
|
||||
* @throws UnexpectedTypeException when the argument is not of the expected type
|
||||
* @throws TransformationFailedException when the transformation fails
|
||||
*/
|
||||
function reverseTransform($value);
|
||||
public function reverseTransform($value);
|
||||
}
|
||||
|
@ -18,5 +18,5 @@ interface ChoiceListInterface
|
||||
*
|
||||
* @return array
|
||||
*/
|
||||
function getChoices();
|
||||
public function getChoices();
|
||||
}
|
||||
|
@ -22,7 +22,7 @@ class TimezoneChoiceList implements ChoiceListInterface
|
||||
* Stores the available timezone choices
|
||||
* @var array
|
||||
*/
|
||||
static protected $timezones;
|
||||
protected static $timezones;
|
||||
|
||||
/**
|
||||
* Returns the timezone choices.
|
||||
|
@ -159,6 +159,7 @@ class DateTimeToLocalizedStringTransformer extends BaseDateTimeTransformer
|
||||
|
||||
$intlDateFormatter = new \IntlDateFormatter(\Locale::getDefault(), $dateFormat, $timeFormat, $timezone, $calendar, $pattern);
|
||||
$intlDateFormatter->setLenient(false);
|
||||
|
||||
return $intlDateFormatter;
|
||||
}
|
||||
}
|
||||
|
@ -30,7 +30,7 @@ class FixRadioInputListener implements EventSubscriberInterface
|
||||
$event->setData(strlen($data) < 1 ? array() : array($data => true));
|
||||
}
|
||||
|
||||
static public function getSubscribedEvents()
|
||||
public static function getSubscribedEvents()
|
||||
{
|
||||
return array(FormEvents::BIND_CLIENT_DATA => 'onBindClientData');
|
||||
}
|
||||
|
@ -38,7 +38,7 @@ class FixUrlProtocolListener implements EventSubscriberInterface
|
||||
}
|
||||
}
|
||||
|
||||
static public function getSubscribedEvents()
|
||||
public static function getSubscribedEvents()
|
||||
{
|
||||
return array(FormEvents::BIND_NORM_DATA => 'onBindNormData');
|
||||
}
|
||||
|
@ -61,7 +61,7 @@ class ResizeFormListener implements EventSubscriberInterface
|
||||
$this->options = $options;
|
||||
}
|
||||
|
||||
static public function getSubscribedEvents()
|
||||
public static function getSubscribedEvents()
|
||||
{
|
||||
return array(
|
||||
FormEvents::PRE_SET_DATA => 'preSetData',
|
||||
|
@ -31,7 +31,7 @@ class TrimListener implements EventSubscriberInterface
|
||||
}
|
||||
}
|
||||
|
||||
static public function getSubscribedEvents()
|
||||
public static function getSubscribedEvents()
|
||||
{
|
||||
return array(FormEvents::BIND_CLIENT_DATA => 'onBindClientData');
|
||||
}
|
||||
|
@ -80,7 +80,7 @@ class MoneyType extends AbstractType
|
||||
* The pattern contains the placeholder "{{ widget }}" where the HTML tag should
|
||||
* be inserted
|
||||
*/
|
||||
static private function getPattern($currency)
|
||||
private static function getPattern($currency)
|
||||
{
|
||||
if (!$currency) {
|
||||
return '{{ widget }}';
|
||||
|
@ -104,7 +104,7 @@ class DelegatingValidator implements FormValidatorInterface
|
||||
* @param FormInterface $form The validated form
|
||||
* @param ExecutionContext $context The current validation context
|
||||
*/
|
||||
static public function validateFormData(FormInterface $form, ExecutionContext $context)
|
||||
public static function validateFormData(FormInterface $form, ExecutionContext $context)
|
||||
{
|
||||
if (is_object($form->getData()) || is_array($form->getData())) {
|
||||
$propertyPath = $context->getPropertyPath();
|
||||
@ -127,7 +127,7 @@ class DelegatingValidator implements FormValidatorInterface
|
||||
}
|
||||
}
|
||||
|
||||
static protected function getFormValidationGroups(FormInterface $form)
|
||||
protected static function getFormValidationGroups(FormInterface $form)
|
||||
{
|
||||
$groups = null;
|
||||
|
||||
|
@ -23,7 +23,7 @@ interface FormExtensionInterface
|
||||
*
|
||||
* @return FormTypeInterface The type
|
||||
*/
|
||||
function getType($name);
|
||||
public function getType($name);
|
||||
|
||||
/**
|
||||
* Returns whether the given type is supported.
|
||||
@ -32,7 +32,7 @@ interface FormExtensionInterface
|
||||
*
|
||||
* @return Boolean Whether the type is supported by this extension
|
||||
*/
|
||||
function hasType($name);
|
||||
public function hasType($name);
|
||||
|
||||
/**
|
||||
* Returns the extensions for the given type.
|
||||
@ -41,7 +41,7 @@ interface FormExtensionInterface
|
||||
*
|
||||
* @return array An array of extensions as FormTypeExtensionInterface instances
|
||||
*/
|
||||
function getTypeExtensions($name);
|
||||
public function getTypeExtensions($name);
|
||||
|
||||
/**
|
||||
* Returns whether this extension provides type extensions for the given type.
|
||||
@ -50,12 +50,12 @@ interface FormExtensionInterface
|
||||
*
|
||||
* @return Boolean Whether the given type has extensions
|
||||
*/
|
||||
function hasTypeExtensions($name);
|
||||
public function hasTypeExtensions($name);
|
||||
|
||||
/**
|
||||
* Returns the type guesser provided by this extension.
|
||||
*
|
||||
* @return FormTypeGuesserInterface|null The type guesser
|
||||
*/
|
||||
function getTypeGuesser();
|
||||
public function getTypeGuesser();
|
||||
}
|
||||
|
@ -26,7 +26,7 @@ interface FormFactoryInterface
|
||||
*
|
||||
* @throws FormException if any given option is not applicable to the given type
|
||||
*/
|
||||
function create($type, $data = null, array $options = array());
|
||||
public function create($type, $data = null, array $options = array());
|
||||
|
||||
/**
|
||||
* Returns a form.
|
||||
@ -40,7 +40,7 @@ interface FormFactoryInterface
|
||||
*
|
||||
* @throws FormException if any given option is not applicable to the given type
|
||||
*/
|
||||
function createNamed($type, $name, $data = null, array $options = array());
|
||||
public function createNamed($type, $name, $data = null, array $options = array());
|
||||
|
||||
/**
|
||||
* Returns a form for a property of a class.
|
||||
@ -54,7 +54,7 @@ interface FormFactoryInterface
|
||||
*
|
||||
* @throws FormException if any given option is not applicable to the form type
|
||||
*/
|
||||
function createForProperty($class, $property, $data = null, array $options = array());
|
||||
public function createForProperty($class, $property, $data = null, array $options = array());
|
||||
|
||||
/**
|
||||
* Returns a form builder
|
||||
@ -67,7 +67,7 @@ interface FormFactoryInterface
|
||||
*
|
||||
* @throws FormException if any given option is not applicable to the given type
|
||||
*/
|
||||
function createBuilder($type, $data = null, array $options = array());
|
||||
public function createBuilder($type, $data = null, array $options = array());
|
||||
|
||||
/**
|
||||
* Returns a form builder.
|
||||
@ -81,7 +81,7 @@ interface FormFactoryInterface
|
||||
*
|
||||
* @throws FormException if any given option is not applicable to the given type
|
||||
*/
|
||||
function createNamedBuilder($type, $name, $data = null, array $options = array());
|
||||
public function createNamedBuilder($type, $name, $data = null, array $options = array());
|
||||
|
||||
/**
|
||||
* Returns a form builder for a property of a class.
|
||||
@ -98,11 +98,11 @@ interface FormFactoryInterface
|
||||
*
|
||||
* @throws FormException if any given option is not applicable to the form type
|
||||
*/
|
||||
function createBuilderForProperty($class, $property, $data = null, array $options = array());
|
||||
public function createBuilderForProperty($class, $property, $data = null, array $options = array());
|
||||
|
||||
function getType($name);
|
||||
public function getType($name);
|
||||
|
||||
function hasType($name);
|
||||
public function hasType($name);
|
||||
|
||||
function addType(FormTypeInterface $type);
|
||||
public function addType(FormTypeInterface $type);
|
||||
}
|
||||
|
@ -23,28 +23,28 @@ interface FormInterface extends \ArrayAccess, \Traversable, \Countable
|
||||
*
|
||||
* @param FormInterface $parent The parent form
|
||||
*/
|
||||
function setParent(FormInterface $parent = null);
|
||||
public function setParent(FormInterface $parent = null);
|
||||
|
||||
/**
|
||||
* Returns the parent form.
|
||||
*
|
||||
* @return FormInterface The parent form
|
||||
*/
|
||||
function getParent();
|
||||
public function getParent();
|
||||
|
||||
/**
|
||||
* Returns whether the form has a parent.
|
||||
*
|
||||
* @return Boolean
|
||||
*/
|
||||
function hasParent();
|
||||
public function hasParent();
|
||||
|
||||
/**
|
||||
* Adds a child to the form.
|
||||
*
|
||||
* @param FormInterface $child The FormInterface to add as a child
|
||||
*/
|
||||
function add(FormInterface $child);
|
||||
public function add(FormInterface $child);
|
||||
|
||||
/**
|
||||
* Returns whether a child with the given name exists.
|
||||
@ -53,35 +53,35 @@ interface FormInterface extends \ArrayAccess, \Traversable, \Countable
|
||||
*
|
||||
* @return Boolean
|
||||
*/
|
||||
function has($name);
|
||||
public function has($name);
|
||||
|
||||
/**
|
||||
* Removes a child from the form.
|
||||
*
|
||||
* @param string $name The name of the child to remove
|
||||
*/
|
||||
function remove($name);
|
||||
public function remove($name);
|
||||
|
||||
/**
|
||||
* Returns all children in this group.
|
||||
*
|
||||
* @return array An array of FormInterface instances
|
||||
*/
|
||||
function getChildren();
|
||||
public function getChildren();
|
||||
|
||||
/**
|
||||
* Return whether the form has children.
|
||||
*
|
||||
* @return Boolean
|
||||
*/
|
||||
function hasChildren();
|
||||
public function hasChildren();
|
||||
|
||||
/**
|
||||
* Returns all errors.
|
||||
*
|
||||
* @return array An array of FormError instances that occurred during binding
|
||||
*/
|
||||
function getErrors();
|
||||
public function getErrors();
|
||||
|
||||
/**
|
||||
* Updates the field with default data.
|
||||
@ -90,14 +90,14 @@ interface FormInterface extends \ArrayAccess, \Traversable, \Countable
|
||||
*
|
||||
* @return Form The current form
|
||||
*/
|
||||
function setData($appData);
|
||||
public function setData($appData);
|
||||
|
||||
/**
|
||||
* Returns the data in the format needed for the underlying object.
|
||||
*
|
||||
* @return mixed
|
||||
*/
|
||||
function getData();
|
||||
public function getData();
|
||||
|
||||
/**
|
||||
* Returns the normalized data of the field.
|
||||
@ -106,56 +106,56 @@ interface FormInterface extends \ArrayAccess, \Traversable, \Countable
|
||||
* When the field is bound, the normalized bound data is
|
||||
* returned if the field is valid, null otherwise.
|
||||
*/
|
||||
function getNormData();
|
||||
public function getNormData();
|
||||
|
||||
/**
|
||||
* Returns the data transformed by the value transformer.
|
||||
*
|
||||
* @return string
|
||||
*/
|
||||
function getClientData();
|
||||
public function getClientData();
|
||||
|
||||
/**
|
||||
* Returns the extra data.
|
||||
*
|
||||
* @return array The bound data which do not belong to a child
|
||||
*/
|
||||
function getExtraData();
|
||||
public function getExtraData();
|
||||
|
||||
/**
|
||||
* Returns whether the field is bound.
|
||||
*
|
||||
* @return Boolean true if the form is bound to input values, false otherwise
|
||||
*/
|
||||
function isBound();
|
||||
public function isBound();
|
||||
|
||||
/**
|
||||
* Returns the supported types.
|
||||
*
|
||||
* @return array An array of FormTypeInterface
|
||||
*/
|
||||
function getTypes();
|
||||
public function getTypes();
|
||||
|
||||
/**
|
||||
* Returns the name by which the form is identified in forms.
|
||||
*
|
||||
* @return string The name of the form.
|
||||
*/
|
||||
function getName();
|
||||
public function getName();
|
||||
|
||||
/**
|
||||
* Adds an error to this form.
|
||||
*
|
||||
* @param FormError $error
|
||||
*/
|
||||
function addError(FormError $error);
|
||||
public function addError(FormError $error);
|
||||
|
||||
/**
|
||||
* Returns whether the form is valid.
|
||||
*
|
||||
* @return Boolean
|
||||
*/
|
||||
function isValid();
|
||||
public function isValid();
|
||||
|
||||
/**
|
||||
* Returns whether the form is required to be filled out.
|
||||
@ -166,7 +166,7 @@ interface FormInterface extends \ArrayAccess, \Traversable, \Countable
|
||||
*
|
||||
* @return Boolean
|
||||
*/
|
||||
function isRequired();
|
||||
public function isRequired();
|
||||
|
||||
/**
|
||||
* Returns whether this form can be read only.
|
||||
@ -179,56 +179,56 @@ interface FormInterface extends \ArrayAccess, \Traversable, \Countable
|
||||
*
|
||||
* @return Boolean
|
||||
*/
|
||||
function isReadOnly();
|
||||
public function isReadOnly();
|
||||
|
||||
/**
|
||||
* Returns whether the form is empty.
|
||||
*
|
||||
* @return Boolean
|
||||
*/
|
||||
function isEmpty();
|
||||
public function isEmpty();
|
||||
|
||||
/**
|
||||
* Returns whether the data in the different formats is synchronized.
|
||||
*
|
||||
* @return Boolean
|
||||
*/
|
||||
function isSynchronized();
|
||||
public function isSynchronized();
|
||||
|
||||
/**
|
||||
* Writes data into the form.
|
||||
*
|
||||
* @param mixed $data The data
|
||||
*/
|
||||
function bind($data);
|
||||
public function bind($data);
|
||||
|
||||
/**
|
||||
* Returns whether the form has an attribute with the given name.
|
||||
*
|
||||
* @param string $name The name of the attribute
|
||||
*/
|
||||
function hasAttribute($name);
|
||||
public function hasAttribute($name);
|
||||
|
||||
/**
|
||||
* Returns the value of the attributes with the given name.
|
||||
*
|
||||
* @param string $name The name of the attribute
|
||||
*/
|
||||
function getAttribute($name);
|
||||
public function getAttribute($name);
|
||||
|
||||
/**
|
||||
* Returns the root of the form tree.
|
||||
*
|
||||
* @return FormInterface The root of the tree
|
||||
*/
|
||||
function getRoot();
|
||||
public function getRoot();
|
||||
|
||||
/**
|
||||
* Returns whether the field is the root of the form tree.
|
||||
*
|
||||
* @return Boolean
|
||||
*/
|
||||
function isRoot();
|
||||
public function isRoot();
|
||||
|
||||
/**
|
||||
* Creates a view.
|
||||
@ -237,5 +237,5 @@ interface FormInterface extends \ArrayAccess, \Traversable, \Countable
|
||||
*
|
||||
* @return FormView The view
|
||||
*/
|
||||
function createView(FormView $parent = null);
|
||||
public function createView(FormView $parent = null);
|
||||
}
|
||||
|
@ -24,7 +24,7 @@ interface FormTypeExtensionInterface
|
||||
* @param FormBuilder $builder The form builder
|
||||
* @param array $options The options
|
||||
*/
|
||||
function buildForm(FormBuilder $builder, array $options);
|
||||
public function buildForm(FormBuilder $builder, array $options);
|
||||
|
||||
/**
|
||||
* Builds the view.
|
||||
@ -37,7 +37,7 @@ interface FormTypeExtensionInterface
|
||||
* @param FormView $view The view
|
||||
* @param FormInterface $form The form
|
||||
*/
|
||||
function buildView(FormView $view, FormInterface $form);
|
||||
public function buildView(FormView $view, FormInterface $form);
|
||||
|
||||
/**
|
||||
* Builds the view.
|
||||
@ -50,7 +50,7 @@ interface FormTypeExtensionInterface
|
||||
* @param FormView $view The view
|
||||
* @param FormInterface $form The form
|
||||
*/
|
||||
function buildViewBottomUp(FormView $view, FormInterface $form);
|
||||
public function buildViewBottomUp(FormView $view, FormInterface $form);
|
||||
|
||||
/**
|
||||
* Overrides the default options form the extended type.
|
||||
@ -59,7 +59,7 @@ interface FormTypeExtensionInterface
|
||||
*
|
||||
* @return array
|
||||
*/
|
||||
function getDefaultOptions(array $options);
|
||||
public function getDefaultOptions(array $options);
|
||||
|
||||
/**
|
||||
* Returns the allowed option values for each option (if any).
|
||||
@ -68,13 +68,12 @@ interface FormTypeExtensionInterface
|
||||
*
|
||||
* @return array The allowed option values
|
||||
*/
|
||||
function getAllowedOptionValues(array $options);
|
||||
|
||||
public function getAllowedOptionValues(array $options);
|
||||
|
||||
/**
|
||||
* Returns the name of the type being extended
|
||||
*
|
||||
* @return string The name of the type being extended
|
||||
*/
|
||||
function getExtendedType();
|
||||
public function getExtendedType();
|
||||
}
|
||||
|
@ -21,7 +21,7 @@ interface FormTypeGuesserInterface
|
||||
*
|
||||
* @return TypeGuess A guess for the field's type and options
|
||||
*/
|
||||
function guessType($class, $property);
|
||||
public function guessType($class, $property);
|
||||
|
||||
/**
|
||||
* Returns a guess whether a property of a class is required
|
||||
@ -31,7 +31,7 @@ interface FormTypeGuesserInterface
|
||||
*
|
||||
* @return Guess A guess for the field's required setting
|
||||
*/
|
||||
function guessRequired($class, $property);
|
||||
public function guessRequired($class, $property);
|
||||
|
||||
/**
|
||||
* Returns a guess about the field's maximum length
|
||||
@ -41,7 +41,7 @@ interface FormTypeGuesserInterface
|
||||
*
|
||||
* @return Guess A guess for the field's maximum length
|
||||
*/
|
||||
function guessMaxLength($class, $property);
|
||||
public function guessMaxLength($class, $property);
|
||||
|
||||
/**
|
||||
* Returns a guess about the field's minimum length
|
||||
@ -51,6 +51,6 @@ interface FormTypeGuesserInterface
|
||||
*
|
||||
* @return Guess A guess for the field's minimum length
|
||||
*/
|
||||
function guessMinLength($class, $property);
|
||||
public function guessMinLength($class, $property);
|
||||
|
||||
}
|
||||
|
@ -25,7 +25,7 @@ interface FormTypeInterface
|
||||
* @param FormBuilder $builder The form builder
|
||||
* @param array $options The options
|
||||
*/
|
||||
function buildForm(FormBuilder $builder, array $options);
|
||||
public function buildForm(FormBuilder $builder, array $options);
|
||||
|
||||
/**
|
||||
* Builds the form view.
|
||||
@ -39,7 +39,7 @@ interface FormTypeInterface
|
||||
* @param FormView $view The view
|
||||
* @param FormInterface $form The form
|
||||
*/
|
||||
function buildView(FormView $view, FormInterface $form);
|
||||
public function buildView(FormView $view, FormInterface $form);
|
||||
|
||||
/**
|
||||
* Builds the form view.
|
||||
@ -56,7 +56,7 @@ interface FormTypeInterface
|
||||
* @param FormView $view The view
|
||||
* @param FormInterface $form The form
|
||||
*/
|
||||
function buildViewBottomUp(FormView $view, FormInterface $form);
|
||||
public function buildViewBottomUp(FormView $view, FormInterface $form);
|
||||
|
||||
/**
|
||||
* Returns a builder for the current type.
|
||||
@ -70,7 +70,7 @@ interface FormTypeInterface
|
||||
*
|
||||
* @return FormBuilder|null A form builder or null when the type does not have a builder
|
||||
*/
|
||||
function createBuilder($name, FormFactoryInterface $factory, array $options);
|
||||
public function createBuilder($name, FormFactoryInterface $factory, array $options);
|
||||
|
||||
/**
|
||||
* Returns the default options for this type.
|
||||
@ -79,7 +79,7 @@ interface FormTypeInterface
|
||||
*
|
||||
* @return array The default options
|
||||
*/
|
||||
function getDefaultOptions(array $options);
|
||||
public function getDefaultOptions(array $options);
|
||||
|
||||
/**
|
||||
* Returns the allowed option values for each option (if any).
|
||||
@ -88,7 +88,7 @@ interface FormTypeInterface
|
||||
*
|
||||
* @return array The allowed option values
|
||||
*/
|
||||
function getAllowedOptionValues(array $options);
|
||||
public function getAllowedOptionValues(array $options);
|
||||
|
||||
/**
|
||||
* Returns the name of the parent type.
|
||||
@ -97,14 +97,14 @@ interface FormTypeInterface
|
||||
*
|
||||
* @return string|null The name of the parent type if any otherwise null
|
||||
*/
|
||||
function getParent(array $options);
|
||||
public function getParent(array $options);
|
||||
|
||||
/**
|
||||
* Returns the name of this type.
|
||||
*
|
||||
* @return string The name of this type
|
||||
*/
|
||||
function getName();
|
||||
public function getName();
|
||||
|
||||
/**
|
||||
* Adds extensions for this type.
|
||||
@ -113,12 +113,12 @@ interface FormTypeInterface
|
||||
*
|
||||
* @throws UnexpectedTypeException if any extension does not implement FormTypeExtensionInterface
|
||||
*/
|
||||
function setExtensions(array $extensions);
|
||||
public function setExtensions(array $extensions);
|
||||
|
||||
/**
|
||||
* Returns the extensions associated with this type.
|
||||
*
|
||||
* @return array An array of FormTypeExtensionInterface
|
||||
*/
|
||||
function getExtensions();
|
||||
public function getExtensions();
|
||||
}
|
||||
|
@ -13,5 +13,5 @@ namespace Symfony\Component\Form;
|
||||
|
||||
interface FormValidatorInterface
|
||||
{
|
||||
function validate(FormInterface $form);
|
||||
public function validate(FormInterface $form);
|
||||
}
|
||||
|
@ -69,7 +69,7 @@ abstract class Guess
|
||||
*
|
||||
* @return Guess The guess with the highest confidence
|
||||
*/
|
||||
static public function getBestGuess(array $guesses)
|
||||
public static function getBestGuess(array $guesses)
|
||||
{
|
||||
usort($guesses, function ($a, $b) {
|
||||
return $b->getConfidence() - $a->getConfidence();
|
||||
|
@ -13,7 +13,7 @@ namespace Symfony\Component\Form\Util;
|
||||
|
||||
abstract class FormUtil
|
||||
{
|
||||
static public function toArrayKey($value)
|
||||
public static function toArrayKey($value)
|
||||
{
|
||||
if (is_bool($value) || (string) (int) $value === (string) $value) {
|
||||
return (int) $value;
|
||||
@ -22,7 +22,7 @@ abstract class FormUtil
|
||||
return (string) $value;
|
||||
}
|
||||
|
||||
static public function toArrayKeys(array $array)
|
||||
public static function toArrayKeys(array $array)
|
||||
{
|
||||
return array_map(array(__CLASS__, 'toArrayKey'), $array);
|
||||
}
|
||||
@ -34,7 +34,7 @@ abstract class FormUtil
|
||||
*
|
||||
* @return Boolean Whether the choice is a group
|
||||
*/
|
||||
static public function isChoiceGroup($choice)
|
||||
public static function isChoiceGroup($choice)
|
||||
{
|
||||
return is_array($choice) || $choice instanceof \Traversable;
|
||||
}
|
||||
@ -47,7 +47,7 @@ abstract class FormUtil
|
||||
*
|
||||
* @return Boolean Whether the choice is selected
|
||||
*/
|
||||
static public function isChoiceSelected($choice, $value)
|
||||
public static function isChoiceSelected($choice, $value)
|
||||
{
|
||||
$choice = static::toArrayKey($choice);
|
||||
|
||||
|
@ -29,7 +29,7 @@ class File extends \SplFileInfo
|
||||
*
|
||||
* @var array
|
||||
*/
|
||||
static protected $defaultExtensions = array(
|
||||
protected static $defaultExtensions = array(
|
||||
'application/andrew-inset' => 'ez',
|
||||
'application/appledouble' => 'base64',
|
||||
'application/applefile' => 'base64',
|
||||
|
@ -26,7 +26,7 @@ class ContentTypeMimeTypeGuesser implements MimeTypeGuesserInterface
|
||||
*
|
||||
* @return Boolean
|
||||
*/
|
||||
static public function isSupported()
|
||||
public static function isSupported()
|
||||
{
|
||||
return function_exists('mime_content_type');
|
||||
}
|
||||
|
@ -26,7 +26,7 @@ class FileBinaryMimeTypeGuesser implements MimeTypeGuesserInterface
|
||||
*
|
||||
* @return Boolean
|
||||
*/
|
||||
static public function isSupported()
|
||||
public static function isSupported()
|
||||
{
|
||||
return !strstr(PHP_OS, 'WIN');
|
||||
}
|
||||
|
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user